You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
JDBC Message Store - Reaper Can Reap Released Group of Messages [INT-2751] #6726
While a message group is in the process of being release normally, it is possible for the reaper to fire and find the same messages. Given that the group is locked (for normal processing), the reaper blocks waiting for the group. After the normal release completes, the messages are removed, and the lock released.
The reaper then continues, but fails to verify that the messages still exist in the group; hence the group is released a second time.
With some databases, Isolation.SERIALIZABLE may avoid the problem, but may cause other deadlocks depending on how the database is being used.
One possible solution will be to acquire the group lock in getMessageGroup() which is called by the reaper via the group store's iterator.
This will cause the reaper to block before doing the query, and the messages will never have existed as far as the reaper is concerned.
JDBC stores message groups with a generated key, based on the correlationId returned from the correlation strategy, instead of under the correlationId itself.
This causes issues with the reaper because it acquires a different lock for the same group, causing duplicate output messages under this JIRA race condition.
Activity
spring-operator commentedon Sep 17, 2012
Gary Russell commented
PR: #627
spring-operator commentedon Sep 18, 2012
Oleg Zhurakousky commented
Merged and cherry-picked cleanly to 2.1
spring-operator commentedon Sep 19, 2012
Gary Russell commented
JDBC stores message groups with a generated key, based on the correlationId returned from the correlation strategy, instead of under the correlationId itself.
This causes issues with the reaper because it acquires a different lock for the same group, causing duplicate output messages under this JIRA race condition.
spring-operator commentedon Sep 19, 2012
Gary Russell commented
Seems like a long-standing JMS MS issue where group.getGroupId() returns the UUID generated from the groupId instead of the original groupId.
spring-operator commentedon Sep 19, 2012
Gary Russell commented
New PR to resolve second issue that causes the same symptoms: #629