I canβt explain in detail why this is happening, but it has something to do with how ConnectionFactory automatically configured.
One way to get rid of this constant restart of the built-in broker is to include the union in application.properties :
spring.activemq.pooled=true
To use this, you also need to add the following dependency to your pom.xml :
<dependency> <groupId>org.apache.activemq</groupId> <artifactId>activemq-pool</artifactId> </dependency>
I dug some documentation and eventually found this
At the bottom of the page, it reads:
Using ActiveMQConnectionFactory
...
A broker will be created when the first connection is created.
...
Again, this does not fully explain what is happening, but I stopped digging as soon as I found that turning on the pool stopped this behavior.
ci_
source share