Try PubSub+

Solace-JMS Dynamic Subscriptions.

What would be the best option to subscribe & unsubscribe to Topics/Queues dynamically with solace-jms with out using @JMSListener?
I could see a couple of options as listed below:
I) Initiating JmsListenerContainerFactory for individual endpoints.
ii) Making use of Connection instance to create JMS Session and having the subscription.

And for un-subscription making use of Session.unsubscribe() method call.


  • AaronAaron Member, Moderator, Employee Posts: 106 Solace Employee

    Just to confirm, this is for Spring, right? And are you intending to use persistent or non-persistent messages? Thanks!

  • arun_xi_kumararun_xi_kumar Member Posts: 3

    Yes, It's Spring based with" solace-jms-spring-boot-starter#3.0.0" dependency;
    We are having both delivery modes.

  • alinaqvialinaqvi Member Posts: 35

    I'll add to this question ... we are trying to use the Spring @JmsListener for both persistent and non-persistent messages. But we would like to have the ability to subscribe and unsubscribe to the endpoints as needed rather than have predefined annotated methods that start subscriptions as soon as the App starts up.
    We also do not know the names of our topics before hand so it will ideally have to be a way to programmatically start and stop subscriptions.


Sign In or Register to comment.