我建议检查您的日志级别。您正在使用 reconnectRetries 等配置正确的东西。
您应该会看到类似下面的内容。我在运行这个应用程序时得到这些日志:https ://github.com/SolaceSamples/solace-samples-spring/blob/master/spring-boot-autoconfig-receiver/src/main/java/com/solace/samples/spring /boot/SpringBootReceiver.java
[2m2021-12-01 13:45:21.742[0;39m [32m INFO[0;39m [35m23127[0;39m [2m---[0;39m [2m[ main][0;39m [36mo.s.b.w.embedded.tomcat.TomcatWebServer [0;39m [2m:[0;39m Tomcat started on port(s): 8081 (http) with context path ''
[2m2021-12-01 13:45:21.825[0;39m [32m INFO[0;39m [35m23127[0;39m [2m---[0;39m [2m[ main][0;39m [36mc.s.j.protocol.impl.TcpClientChannel [0;39m [2m:[0;39m Connecting to host 'orig=tcp://localhost:4444, scheme=tcp://, host=localhost, port=4444' (host 1 of 1, smfclient 1, attempt 1 of 1, this_host_attempt: 1 of 1)
[2m2021-12-01 13:45:21.851[0;39m [32m INFO[0;39m [35m23127[0;39m [2m---[0;39m [2m[ main][0;39m [36mc.s.j.protocol.impl.TcpClientChannel [0;39m [2m:[0;39m Connected to host 'orig=tcp://localhost:4444, scheme=tcp://, host=localhost, port=4444' (smfclient 1)
[2m2021-12-01 13:45:21.890[0;39m [32m INFO[0;39m [35m23127[0;39m [2m---[0;39m [2m[ main][0;39m [36mc.s.s.spring.boot.SpringBootReceiver [0;39m [2m:[0;39m Started SpringBootReceiver in 3.494 seconds (JVM running for 4.445)
[2m2021-12-01 13:45:24.475[0;39m [32m INFO[0;39m [35m23127[0;39m [2m---[0;39m [2m[on(1)-127.0.0.1][0;39m [36mo.a.c.c.C.[Tomcat].[localhost].[/] [0;39m [2m:[0;39m Initializing Spring DispatcherServlet 'dispatcherServlet'
[2m2021-12-01 13:45:24.475[0;39m [32m INFO[0;39m [35m23127[0;39m [2m---[0;39m [2m[on(1)-127.0.0.1][0;39m [36mo.s.web.servlet.DispatcherServlet [0;39m [2m:[0;39m Initializing Servlet 'dispatcherServlet'
[2m2021-12-01 13:45:24.477[0;39m [32m INFO[0;39m [35m23127[0;39m [2m---[0;39m [2m[on(1)-127.0.0.1][0;39m [36mo.s.web.servlet.DispatcherServlet [0;39m [2m:[0;39m Completed initialization in 2 ms
[2m2021-12-01 13:45:46.310[0;39m [32m INFO[0;39m [35m23127[0;39m [2m---[0;39m [2m[2_ReactorThread][0;39m [36mc.s.jcsmp.impl.flow.UnbindRequestTask [0;39m [2m:[0;39m Error Response (503) - Service Unavailable; subCode: 50; flowId=0
[2m2021-12-01 13:45:46.326[0;39m [33m WARN[0;39m [35m23127[0;39m [2m---[0;39m [2m[ntContainer#0-1][0;39m [36mo.s.j.l.DefaultMessageListenerContainer [0;39m [2m:[0;39m Setup of JMS message listener invoker failed for destination 'SpringTestQueue' - trying to recover. Cause: Error receiving message - internal error (503: Unknown Queue)
[2m2021-12-01 13:45:46.332[0;39m [32m INFO[0;39m [35m23127[0;39m [2m---[0;39m [2m[ntContainer#0-1][0;39m [36mc.s.j.protocol.impl.TcpClientChannel [0;39m [2m:[0;39m Channel Closed (smfclient 1)
[2m2021-12-01 13:45:46.355[0;39m [32m INFO[0;39m [35m23127[0;39m [2m---[0;39m [2m[ntContainer#0-1][0;39m [36mc.s.j.protocol.impl.TcpClientChannel [0;39m [2m:[0;39m Connecting to host 'orig=tcp://localhost:4444, scheme=tcp://, host=localhost, port=4444' (host 1 of 1, smfclient 2, attempt 1 of 1, this_host_attempt: 1 of 1)
[2m2021-12-01 13:45:46.370[0;39m [32m INFO[0;39m [35m23127[0;39m [2m---[0;39m [2m[ntContainer#0-1][0;39m [36mc.s.j.protocol.impl.TcpClientChannel [0;39m [2m:[0;39m Connected to host 'orig=tcp://localhost:4444, scheme=tcp://, host=localhost, port=4444' (smfclient 2)
[2m2021-12-01 13:45:51.390[0;39m [33m WARN[0;39m [35m23127[0;39m [2m---[0;39m [2m[ntContainer#0-2][0;39m [36mo.s.j.l.DefaultMessageListenerContainer [0;39m [2m:[0;39m Setup of JMS message listener invoker failed for destination 'SpringTestQueue' - trying to recover. Cause: Error creating consumer - unknown endpoint (503: Unknown Queue)
[2m2021-12-01 13:45:51.391[0;39m [32m INFO[0;39m [35m23127[0;39m [2m---[0;39m [2m[ntContainer#0-2][0;39m [36mc.s.j.protocol.impl.TcpClientChannel [0;39m [2m:[0;39m Channel Closed (smfclient 2)
[2m2021-12-01 13:45:51.397[0;39m [32m INFO[0;39m [35m23127[0;39m [2m---[0;39m [2m[ntContainer#0-2][0;39m [36mc.s.j.protocol.impl.TcpClientChannel [0;39m [2m:[0;39m Connecting to host 'orig=tcp://localhost:4444, scheme=tcp://, host=localhost, port=4444' (host 1 of 1, smfclient 3, attempt 1 of 1, this_host_attempt: 1 of 1)
[2m2021-12-01 13:45:51.408[0;39m [32m INFO[0;39m [35m23127[0;39m [2m---[0;39m [2m[ntContainer#0-2][0;39m [36mc.s.j.protocol.impl.TcpClientChannel [0;39m [2m:[0;39m Connected to host 'orig=tcp://localhost:4444, scheme=tcp://, host=localhost, port=4444' (smfclient 3)
[2m2021-12-01 13:45:56.426[0;39m [33m WARN[0;39m [35m23127[0;39m [2m---[0;39m [2m[ntContainer#0-3][0;39m [36mo.s.j.l.DefaultMessageListenerContainer [0;39m [2m:[0;39m Setup of JMS message listener invoker failed for destination 'SpringTestQueue' - trying to recover. Cause: Error creating consumer - unknown endpoint (503: Unknown Queue)
[2m2021-12-01 13:45:56.427[0;39m [32m INFO[0;39m [35m23127[0;39m [2m---[0;39m [2m[ntContainer#0-3][0;39m [36mc.s.j.protocol.impl.TcpClientChannel [0;39m [2m:[0;39m Channel Closed (smfclient 3)
[2m2021-12-01 13:45:56.434[0;39m [32m INFO[0;39m [35m23127[0;39m [2m---[0;39m [2m[ntContainer#0-3][0;39m [36mc.s.j.protocol.impl.TcpClientChannel [0;39m [2m:[0;39m Connecting to host 'orig=tcp://localhost:4444, scheme=tcp://, host=localhost, port=4444' (host 1 of 1, smfclient 4, attempt 1 of 1, this_host_attempt: 1 of 1)
[2m2021-12-01 13:45:56.441[0;39m [32m INFO[0;39m [35m23127[0;39m [2m---[0;39m [2m[ntContainer#0-3][0;39m [36mc.s.j.protocol.impl.TcpClientChannel [0;39m [2m:[0;39m Connected to host 'orig=tcp://localhost:4444, scheme=tcp://, host=localhost, port=4444' (smfclient 4)
[2m2021-12-01 13:46:01.454[0;39m [33m WARN[0;39m [35m23127[0;39m [2m---[0;39m [2m[ntContainer#0-4][0;39m [36mo.s.j.l.DefaultMessageListenerContainer [0;39m [2m:[0;39m Setup of JMS message listener invoker failed for destination 'SpringTestQueue' - trying to recover. Cause: Error creating consumer - unknown endpoint (503: Unknown Queue)
[2m2021-12-01 13:46:01.455[0;39m [32m INFO[0;39m [35m23127[0;39m [2m---[0;39m [2m[ntContainer#0-4][0;39m [36mc.s.j.protocol.impl.TcpClientChannel [0;39m [2m:[0;39m Channel Closed (smfclient 4)
[2m2021-12-01 13:46:01.463[0;39m [32m INFO[0;39m [35m23127[0;39m [2m---[0;39m [2m[ntContainer#0-4][0;39m [36mc.s.j.protocol.impl.TcpClientChannel [0;39m [2m:[0;39m Connecting to host 'orig=tcp://localhost:4444, scheme=tcp://, host=localhost, port=4444' (host 1 of 1, smfclient 5, attempt 1 of 1, this_host_attempt: 1 of 1)
[2m2021-12-01 13:46:01.473[0;39m [32m INFO[0;39m [35m23127[0;39m [2m---[0;39m [2m[ntContainer#0-4][0;39m [36mc.s.j.protocol.impl.TcpClientChannel [0;39m [2m:[0;39m Connected to host 'orig=tcp://localhost:4444, scheme=tcp://, host=localhost, port=4444' (smfclient 5)