Add back synchronization to avoid corrupted subscription input/output streams
- Prevent simultaneous write of subscribe/unsubscribe using the same Connection - Fix test failure by re-initializing "done" state of SubscriptionTask between runs and adding waits
This commit is contained in:
@@ -207,6 +207,10 @@ public class PubSubResubscribeTests {
|
||||
container.addMessageListener(adapter,
|
||||
Arrays.asList(new Topic[] { new ChannelTopic(CHANNEL), new PatternTopic("s*") }));
|
||||
container.start();
|
||||
|
||||
// Wait for async subscription tasks to setup
|
||||
Thread.sleep(1000);
|
||||
|
||||
template.convertAndSend("somechannel", "HELLO");
|
||||
template.convertAndSend(CHANNEL, "WORLD");
|
||||
|
||||
|
||||
Reference in New Issue
Block a user