mirror of
https://github.com/spring-projects/spring-framework
synced 2026-06-08 17:33:33 +00:00
07fd7606e7
Prior to this commit, when using durable subscribers with @JmsListener methods that do not specify a custom subscription name the generated default subscription name was always org.springframework.jms.listener.adapter.MessagingMessageListenerAdapter. Consequently, multiple such @JmsListener methods were assigned the same subscription name which violates the uniqueness requirement. To address this, MessagingMessageListenerAdapter now implements SubscriptionNameProvider and generates the subscription name based on the following rules. - if the InvocableHandlerMethod is present, the subscription name will take the form of handlerMethod.getBeanType().getName() + "#" + handlerMethod.getMethod().getName(). - otherwise, getClass().getName() is used, which is analogous to the previous behavior. Closes gh-29902