-
Notifications
You must be signed in to change notification settings - Fork 68
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
[feature] Set/get topic schema compatibility strategy #784
[feature] Set/get topic schema compatibility strategy #784
Conversation
Introduce set/get
Update README
// SetSchemaCompatibilityStrategy sets the strategy used to check the a new schema provided | ||
// by a producer is compatible with the current schema before it is installed | ||
SetSchemaCompatibilityStrategy(topic utils.TopicName, | ||
strategy utils.SchemaCompatibilityStrategy) error |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You need to add a new structure SchemaCompatibilityStrategyV2
, link to https://github.com/apache/pulsar/blob/master/pulsar-client-admin-api/src/main/java/org/apache/pulsar/common/policies/data/SchemaCompatibilityStrategy.java#L24
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, could you explain a little more? Are the values in each expected to differ? Or is a separate strategy required for another reason?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There are different values here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok, I'll take a look
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good contribution! But you only add API methods, maybe you also need to add this feature for the CLI.
Fixes #783
Motivation
pulsarctl
cannot be used to set topic level schema compatibility strategies.Modifications
Added get/set commands for topic.
Verifying this change
This change is a trivial rework / code cleanup without any test coverage.
Documentation
Check the box below.
Need to update docs?
doc-required
no-need-doc
doc
pulsar-admin
.