Reputation: 387
I have configured Spring JMS in my project. Now my requirement is that messages are read only when the flag in a properties file in ON.
what are ways to implement this in Spring?
Upvotes: 2
Views: 1685
Reputation: 174749
When asking questions like this, it's always best to show your configuration so people can provide a very specific answer.
The general solution is to use the property to set the autoStartup
property to false
on the listener container, or listener container factory (if using @JmsListener
annotations).
Use a property placeholder, e.g. ${should.start}
.
Upvotes: 5