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

[FLINK-26387][connector/kafka] Use individual multi-broker cluster in broker failure tests #18965

Closed
wants to merge 2 commits into from

Conversation

PatrickRen
Copy link
Contributor

What is the purpose of the change

This pull request fixes a flaky broker failure test that should use multi-broker cluster for replicating partitions during the test run.

Brief change log

  • Use individual multi-broker cluster in broker failure tests
  • Re-enable ignored tests

Verifying this change

This change is already covered by existing broker failure tests.

Does this pull request potentially affect one of the following parts:

  • Dependencies (does it add or upgrade a dependency): (yes / no)
  • The public API, i.e., is any changed class annotated with @Public(Evolving): (yes / no)
  • The serializers: (yes / no / don't know)
  • The runtime per-record code paths (performance sensitive): (yes / no / don't know)
  • Anything that affects deployment or recovery: JobManager (and its components), Checkpointing, Kubernetes/Yarn, ZooKeeper: (yes / no / don't know)
  • The S3 file system connector: (yes / no / don't know)

Documentation

  • Does this pull request introduce a new feature? (yes / no)
  • If yes, how is the feature documented? (not applicable / docs / JavaDocs / not documented)

@flinkbot
Copy link
Collaborator

flinkbot commented Mar 3, 2022

CI report:

Bot commands The @flinkbot bot supports the following commands:
  • @flinkbot run azure re-run the last Azure build

Copy link
Contributor

@leonardBang leonardBang left a comment

Choose a reason for hiding this comment

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

Thanks @PatrickRen for the contribution, I left several comments

Comment on lines +2624 to +2627
hasBeenCheckpointedBeforeFailure = hasBeenCheckpointed;
killedLeaderBefore = true;
Copy link
Contributor

Choose a reason for hiding this comment

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

This should be a bug in your last PR and now you correct this IIUC, aha?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yep exactly 👍 Sorry for being so careless

Comment on lines -499 to -511

private KafkaConsumer<Void, Void> createTempConsumer() {
Properties consumerProps = new Properties();
consumerProps.putAll(getStandardProperties());
consumerProps.setProperty(
ConsumerConfig.KEY_DESERIALIZER_CLASS_CONFIG,
VoidDeserializer.class.getCanonicalName());
consumerProps.setProperty(
ConsumerConfig.VALUE_DESERIALIZER_CLASS_CONFIG,
VoidDeserializer.class.getCanonicalName());
consumerProps.setProperty(ConsumerConfig.ALLOW_AUTO_CREATE_TOPICS_CONFIG, "false");
return new KafkaConsumer<>(consumerProps);
}
Copy link
Contributor

Choose a reason for hiding this comment

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

plz check the IDE warning before open a PR thus we can avoid this kind of minor issue.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks for the reminder! This class has too much warnings (technical debt) so I didn't notice this one 😞 Maybe we need a giant refactor on Kafka test utils in the future. They are deeply bound with the legacy FlinkKafkaProducer and FlinkKafkaConsumer now so a lots of horrible warnings in IDE.

@PatrickRen
Copy link
Contributor Author

Thanks @leonardBang for the review! I made another push just now. Please have a look when you are available.

Copy link
Contributor

@leonardBang leonardBang left a comment

Choose a reason for hiding this comment

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

Thanks @PatrickRen for the update, LGTM

JasonLeeCoding pushed a commit to JasonLeeCoding/flink that referenced this pull request May 27, 2022
zstraw pushed a commit to zstraw/flink that referenced this pull request Jul 4, 2022
jnh5y pushed a commit to jnh5y/flink that referenced this pull request Dec 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants