You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by "lhotari (via GitHub)" <gi...@apache.org> on 2023/02/03 09:10:17 UTC
[GitHub] [pulsar] lhotari opened a new pull request, #19421: [fix][test] Fix flaky test PersistentTopicTest.testGetReplicationClusters
lhotari opened a new pull request, #19421:
URL: https://github.com/apache/pulsar/pull/19421
Fixes #19418
### Motivation
PersistentTopicTest.testGetReplicationClusters fails consistently. PersistentTopic.initialize() is async and the test didn't wait for it's completion.
### Modifications
replace `topic.initialize()` with `topic.initialize().join()` in PersistentTopicTest class.
### Documentation
<!-- DO NOT REMOVE THIS SECTION. CHECK THE PROPER BOX ONLY. -->
- [ ] `doc` <!-- Your PR contains doc changes. -->
- [ ] `doc-required` <!-- Your PR changes impact docs and you will update later -->
- [x] `doc-not-needed` <!-- Your PR changes do not impact docs -->
- [ ] `doc-complete` <!-- Docs have been already added -->
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] lhotari commented on a diff in pull request #19421: [fix][test] Fix flaky test PersistentTopicTest.testGetReplicationClusters
Posted by "lhotari (via GitHub)" <gi...@apache.org>.
lhotari commented on code in PR #19421:
URL: https://github.com/apache/pulsar/pull/19421#discussion_r1095598189
##########
pulsar-broker/src/test/java/org/apache/pulsar/broker/service/PersistentTopicTest.java:
##########
@@ -2251,7 +2251,7 @@ private ByteBuf getMessageWithMetadata(byte[] data) {
@Test
public void testGetReplicationClusters() throws MetadataStoreException {
PersistentTopic topic = new PersistentTopic(successTopicName, ledgerMock, brokerService);
- topic.initialize();
+ topic.initialize().join();
Review Comment:
Yes we do. https://github.com/apache/pulsar/blob/33f40f6154ad20ffadd954d2fbb9fd1ee4268efb/buildtools/src/main/java/org/apache/pulsar/tests/AnnotationListener.java#L49-L52
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] nicoloboschi commented on a diff in pull request #19421: [fix][test] Fix flaky test PersistentTopicTest.testGetReplicationClusters
Posted by "nicoloboschi (via GitHub)" <gi...@apache.org>.
nicoloboschi commented on code in PR #19421:
URL: https://github.com/apache/pulsar/pull/19421#discussion_r1095537423
##########
pulsar-broker/src/test/java/org/apache/pulsar/broker/service/PersistentTopicTest.java:
##########
@@ -2251,7 +2251,7 @@ private ByteBuf getMessageWithMetadata(byte[] data) {
@Test
public void testGetReplicationClusters() throws MetadataStoreException {
PersistentTopic topic = new PersistentTopic(successTopicName, ledgerMock, brokerService);
- topic.initialize();
+ topic.initialize().join();
Review Comment:
do we have a global timeout for single test?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] lhotari merged pull request #19421: [fix][test] Fix flaky test PersistentTopicTest.testGetReplicationClusters
Posted by "lhotari (via GitHub)" <gi...@apache.org>.
lhotari merged PR #19421:
URL: https://github.com/apache/pulsar/pull/19421
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] michaeljmarshall commented on pull request #19421: [fix][test] Fix flaky test PersistentTopicTest.testGetReplicationClusters
Posted by "michaeljmarshall (via GitHub)" <gi...@apache.org>.
michaeljmarshall commented on PR #19421:
URL: https://github.com/apache/pulsar/pull/19421#issuecomment-1416391787
Thank you for taking care of this @lhotari!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org