You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@kafka.apache.org by Patrick Plaatje <pp...@gmail.com> on 2018/05/31 09:22:49 UTC

Issue when using username / password CachedSchemaRegistryClient

Hi,

As this issue is with the Confluent Schema Registry, I'm not sure if this
message is appropriate here, but I'll ask any way :)

We're trying to query the Confluent Schema Registry, which is a external
hosted service we're using, to find all available schemas. The Schema
Registry we are using is protected by a basic username/password combination.

When we try to use the CachedSchemaRegistryClient
(io.confluent.kafka.schemaregistry.client) to query the schema registry,
we're passing the full url, eg:
https://username:password@schemaregistry.url/. Unfortunately this doesn't
seem to work, it's throwing the following exception:

io.confluent.kafka.schemaregistry.client.rest.exceptions.RestClientException:
No content to map due to end-of-input
 at [Source:
sun.net.www.protocol.http.HttpURLConnection$HttpInputStream@4808bc9b; line:
1, column: 1]; error code: 50005
at
io.confluent.kafka.schemaregistry.client.rest.RestService.sendHttpRequest(RestService.java:170)
at
io.confluent.kafka.schemaregistry.client.rest.RestService.httpRequest(RestService.java:188)
at
io.confluent.kafka.schemaregistry.client.rest.RestService.getAllSubjects(RestService.java:386)
at
io.confluent.kafka.schemaregistry.client.rest.RestService.getAllSubjects(RestService.java:381)
at
io.confluent.kafka.schemaregistry.client.CachedSchemaRegistryClient.getAllSubjects(CachedSchemaRegistryClient.java:186)
at
tv.mycujoo.dataplatform.adapters.source.kafka.SchemaFetcher.fetch(SchemaFetcher.java:30)
at
tv.mycujoo.dataplatform.adapters.source.kafka.KafkaAdapter.getAvailableSchemas(KafkaAdapter.java:23)
at tv.mycujoo.dataplatform.Application.main(Application.java:19)
Exception in thread "main" java.lang.NullPointerException
at java.util.ArrayList.<init>(ArrayList.java:178)
at
tv.mycujoo.dataplatform.adapters.source.kafka.SchemaFetcher.fetch(SchemaFetcher.java:35)
at
tv.mycujoo.dataplatform.adapters.source.kafka.KafkaAdapter.getAvailableSchemas(KafkaAdapter.java:23)
at tv.mycujoo.dataplatform.Application.main(Application.java:19)

Would anyone know whether this is a known issue and if there's a way around
it?

Thanks!
-patrick