Alternate expiry algorithm for AbstractMessageGroupStore?
I would like to be able to provide an alternate expiry procedure that is similar to the existing one in AbstractMessageGroupStore.
My goal is to have the message groups expire after a timeout, but only if the message group contains a message of a specific type. If not, I want to the message group to expire later when there exists in the group a message of that specific type.
I could extend SimpleMessageStore and override expireMessageGroups(); perhaps that is a good way to proceed. I also tried to see if a MessageGroupCallback would do the trick but I haven't been able to reason out how that would work.
Or maybe it makes sense to implement my own reaper component?
Can anyone suggest a good approach to achieve this?