Unable to create stream with Schema Registry

This command fails: CREATE STREAM test WITH (KAFKA_TOPIC='test', PARTITIONS=10, VALUE_FORMAT='JSON_SR'); with Schema registry fetch for topic value request failed for topic: test. Whereas, in the schema registry, I can see a schema with test-value as subject. What am I missing?

How are you running ksqlDB server, Kafka, and Schema Registry? Confluent Cloud, or in some other way? I’m wondering if you are configuring ksqlDB server yourself and, if so, if the SR connection params look correct (ksql.schema.registry.url plus any auth params).

The deployment is standalone in a Docker Compose file.

The schema registry should have been schema:8081 and not schema-registry:8081. I should have paid attention to defaults. Apologies!

However, shouldn’t the ksqlDB container errored out since it couldn’t connect to schema registry?

good find!

Are you saying error out at startup? Maybe. It’s a tradeoff whether to couple services and fail fast even when a dependency service isn’t needed, vs doing it at runtime as needed and managing to keep a deployment up more often. Also keep in mind that Schema Registry is optional with ksqlDB – if you create a stream with value format JSON then there’s no need for SR.

Yes.

I do not disagree with you. But, I mean, if I configure the Schema Registry URL, then a “good” start-up should mean the connection to Schema Registry succeeded.

I ended up doing exactly that. :smiley:

This topic was automatically closed after 30 days. New replies are no longer allowed.