Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

explicitly set ksql.schema.registry.url in the server properties file when local start for the ksql-server #367

Merged
merged 1 commit into from
Feb 3, 2020

Conversation

stevenpyzhang
Copy link
Member

What

confluentinc/ksql#4325
Removed the default SR url so now it has to be set in the KSQL server configs. The given server properties file shouldn't have the config specified by default since KSQL can run without Schema Registry configured.

Using the local command requires KSQL to be configured with Schema Registry so it needs to be appended to the server properties file when starting up

References

https://confluentinc.atlassian.net/browse/KSQL-4034

Test&Review

@stevenpyzhang stevenpyzhang requested a review from a team as a code owner January 23, 2020 21:47
Copy link
Contributor

@DABH DABH left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks!

@DABH
Copy link
Contributor

DABH commented Jan 25, 2020

(Note, make sure all CI passes first -- you may need to just re-run some of the tests, CI can be flaky occasionally)

@stevenpyzhang stevenpyzhang merged commit f02ec6c into master Feb 3, 2020
config_service "ksql-server" "ksql" "ksql-server"\
"kafkastore.connection.url" "localhost:${zk_port}"
echo "ksql.schema.registry.url=http://localhost:${schema_registry_port}" \
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

shouldn't this use config_service helper that everything seems to have standardized on?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was trying to follow what config_kafka-rest() was doing originally, but the config didn't seem to be getting picked up by the ksql server

Copy link
Member Author

@stevenpyzhang stevenpyzhang Feb 3, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I did a test with config_service and directly injecting the config, and looked at the resulting message when trying to connect to SR from KSQL. (3333 is a random port)

echo "ksql.schema.registry.url=http://localhost:3333" \
    "${service_dir}/${service}.properties"

Schema registry fetch for topic test request failed.
Caused by: Could not connect to the server.

This is what the behavior should be ^

config_service "ksql-server" "ksql" "ksql-server"\
    "ksql.schema.registry.url" "http://localhost:3333" "reapply"

Avro schema for message values on topic test does not exist in the Schema Registry.Subject: test-value

This indicates that the config wasn't successfully set

@brianstrauch brianstrauch deleted the add-schema-registry-config-ksql-local-start branch June 30, 2021 14:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants