Hello, I created a SpringBoot application (see (1) for used versions) that deploys an AMQP route with my redefined endpoint and my custom connection factory. The beans are defined as follow:
<bean id="amqpConnectionFactory" class="my.package.camel.MyAMQPConnectionFactory" scope="singleton"> <constructor-arg index="0" value="localhost"/> <constructor-arg index="1" value="5672"/> ... </bean> <bean id="amqpCachingConnectionFactory" class="org.springframework.jms.connection.CachingConnectionFactory"> <property name="targetConnectionFactory" ref="amqpConnectionFactory"/> ... </bean> <bean id="amqpEndpoint" class="org.apache.camel.component.amqp.AMQPComponent"> <property name="connectionFactory" ref="amqpCachingConnectionFactory"/> <property name="cacheLevelName" value="CACHE_AUTO"/> <!-- CACHE_AUTO 4 CACHE_CONNECTION 1 CACHE_CONSUMER 3 CACHE_NONE 0 CACHE_SESSION 2 --> ... </bean> Using this configuration, if the target AMQP broker (in my tests I'm using Artemis) is killed and restarted, the AMQP producer is no more able to send messages. The connection is detected as dropped but looks like no new producers are created. If I remove the caching layer the issue is no more present but, as expected, a lot of producers are instantiated (more or less one for each message sent). I did a lot of attempts changing the caching level and/or setting the reconnectOnException to true and cacheProducers to false into the amqpCachingConnectionFactory but without any success. Even setting the heartbeat on connection to 1 minute and waiting for a while didn't solve the issue. Did I miss some configuration parameter? Thanks! Riccardo Modanese (1) SpringBoot 2.5.2 Spring 5.3.8 Camel 3.11.0 Artemis 2.19.0