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

Even if always compatible is set, Consumers cannot be created #12721

Merged
merged 3 commits into from Nov 12, 2021

Conversation

315157973
Copy link
Contributor

Motivation

When the Producer's schema is set to AUTO_PRODUCE_BYTES. Even if always compatible is set, Consumers cannot be created. And return Exception Topic does not have schema to check

Documentation

  • [ x ] no-need-doc

@@ -378,6 +378,9 @@ public String getReplicatorPrefix() {

@Override
public CompletableFuture<Void> checkSchemaCompatibleForConsumer(SchemaData schema) {
if (SchemaCompatibilityStrategy.ALWAYS_COMPATIBLE.equals(schemaCompatibilityStrategy)) {
Copy link
Contributor

Choose a reason for hiding this comment

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

It's better to move into checkConsumerCompatibility() method?

@codelipenghui codelipenghui added this to the 2.10.0 milestone Nov 10, 2021
@github-actions github-actions bot added the doc-not-needed Your PR changes do not impact docs label Nov 10, 2021
@@ -270,6 +270,9 @@ private void checkCompatible(SchemaAndMetadata existingSchema, SchemaData newSch
@Override
public CompletableFuture<Void> checkConsumerCompatibility(String schemaId, SchemaData schemaData,
SchemaCompatibilityStrategy strategy) {
if (SchemaCompatibilityStrategy.ALWAYS_COMPATIBLE.equals(strategy)) {
Copy link
Contributor

Choose a reason for hiding this comment

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

this is an enum, please use "=="

@eolivelli
Copy link
Contributor

over all LGTM

I left one comment

@315157973
Copy link
Contributor Author

over all LGTM

I left one comment

Done

@315157973
Copy link
Contributor Author

@eolivelli PTAL

Copy link
Contributor

@eolivelli eolivelli left a comment

Choose a reason for hiding this comment

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

+1

@eolivelli eolivelli merged commit c3da145 into apache:master Nov 12, 2021
codelipenghui pushed a commit that referenced this pull request Nov 18, 2021
@codelipenghui codelipenghui added cherry-picked/branch-2.8 Archived: 2.8 is end of life release/2.8.2 and removed release/2.8.3 labels Nov 18, 2021
eolivelli pushed a commit to eolivelli/pulsar that referenced this pull request Nov 29, 2021
codelipenghui pushed a commit that referenced this pull request Dec 20, 2021
@codelipenghui codelipenghui added the cherry-picked/branch-2.9 Archived: 2.9 is end of life label Dec 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/broker cherry-picked/branch-2.8 Archived: 2.8 is end of life cherry-picked/branch-2.9 Archived: 2.9 is end of life doc-not-needed Your PR changes do not impact docs release/2.8.2 release/2.9.2
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants