spring-data-redis icon indicating copy to clipboard operation
spring-data-redis copied to clipboard

Pub-Sub Race conditions on high load - Subscription has been unsubscribed and cannot be used anymore

Open IZWO opened this issue 3 years ago • 4 comments

After having a high load, the redis connections get closed automatically and error "Subscription has been unsubscribed and cannot be used anymore" is thrown. We use the pub/sub event. Bypass: if we uncomment the line

redisMessageListenerContainer.addMessageListener(listenerAdapter, new PatternTopic("Dummy"));

then it keeps working. We have 3 Redis Machines in a cluster. See the attached example code and some logging in the target folder.

IZWO avatar Oct 05 '22 11:10 IZWO

Bugfix.zip

IZWO avatar Oct 05 '22 11:10 IZWO

any way to mitigate this issue or work around it? I'm not sure how to recover from it other than restarting our spring server.

captrespect avatar Dec 22 '22 19:12 captrespect

any way to mitigate this issue or work around it? I'm not sure how to recover from it other than restarting our spring server. Yes, with uncommenting the dummy as stated above

IZWO avatar Dec 26 '22 08:12 IZWO