org.springframework.context.ApplicationContextException

Failed to start bean 'org.springframework.jms.config.internalJmsListenerEndpointRegistry'; nested exception is org.springframework.jms.UncategorizedJmsException: Uncategorized exception occurred during JMS processing; nested exception is javax.jms.JMSException: Could not connect to broker URL: tcp://localhost:61616. Reason: java.net.ConnectException: Connection refused: connect

Samebug tips9

To restart the Selenium Webdriver mock browser in a testcase, first use 'driver.close()' and then reinstantiate the driver.

Firewall might be blocking your connection, or MySQL it's not running on your server machine.

Don't give up yet. Our experts can help. Paste your full stack trace to get a solution.

Solutions on the web783

  • Failed to start bean 'org.springframework.jms.config.internalJmsListenerEndpointRegistry'; nested exception is org.springframework.jms.UncategorizedJmsException: Uncategorized exception occurred during JMS processing; nested exception is javax.jms.JMSException: Could not connect to broker URL: tcp://localhost:61616. Reason: java.net.ConnectException: Connection refused: connect
  • Failed to start bean 'xx'; nested exception is org.springframework.jms.UncategorizedJmsException: Uncategorized exception occured during JMS processing; nested exception is javax.jms.JMSException: Could not connect to broker URL: tcp://xx:61616. Reason: java.net.ConnectException: Connection refused: connect
  • Failed to start bean 'xx'; nested exception is org.springframework.jms.UncategorizedJmsException: Uncategorized exception occured during JMS processing; nested exception is javax.jms.JMSException: Could not connect to broker URL: tcp://xx:61616. Reason: java.net.ConnectException: Connection refused: connect
  • Stack trace

    • org.springframework.context.ApplicationContextException: Failed to start bean 'org.springframework.jms.config.internalJmsListenerEndpointRegistry'; nested exception is org.springframework.jms.UncategorizedJmsException: Uncategorized exception occurred during JMS processing; nested exception is javax.jms.JMSException: Could not connect to broker URL: tcp://localhost:61616. Reason: java.net.ConnectException: Connection refused: connect at org.springframework.context.support.DefaultLifecycleProcessor.doStart(DefaultLifecycleProcessor.java:176)[spring-context-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.context.support.DefaultLifecycleProcessor.access$200(DefaultLifecycleProcessor.java:51)[spring-context-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.context.support.DefaultLifecycleProcessor$LifecycleGroup.start(DefaultLifecycleProcessor.java:346)[spring-context-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.context.support.DefaultLifecycleProcessor.startBeans(DefaultLifecycleProcessor.java:149)[spring-context-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.context.support.DefaultLifecycleProcessor.onRefresh(DefaultLifecycleProcessor.java:112)[spring-context-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.context.support.AbstractApplicationContext.finishRefresh(AbstractApplicationContext.java:874)[spring-context-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:544)[spring-context-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:759)[spring-boot-1.4.0.RELEASE.jar:1.4.0.RELEASE] at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:369)[spring-boot-1.4.0.RELEASE.jar:1.4.0.RELEASE] at org.springframework.boot.SpringApplication.run(SpringApplication.java:313)[spring-boot-1.4.0.RELEASE.jar:1.4.0.RELEASE] at org.springframework.boot.SpringApplication.run(SpringApplication.java:1185)[spring-boot-1.4.0.RELEASE.jar:1.4.0.RELEASE] at org.springframework.boot.SpringApplication.run(SpringApplication.java:1174)[spring-boot-1.4.0.RELEASE.jar:1.4.0.RELEASE] at jms.activemq.Application.main(Application.java:37)[main/:na] Caused by: org.springframework.jms.UncategorizedJmsException: Uncategorized exception occurred during JMS processing; nested exception is javax.jms.JMSException: Could not connect to broker URL: tcp://localhost:61616. Reason: java.net.ConnectException: Connection refused: connect at org.springframework.jms.support.JmsUtils.convertJmsAccessException(JmsUtils.java:316)[spring-jms-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.jms.support.JmsAccessor.convertJmsAccessException(JmsAccessor.java:169)[spring-jms-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.jms.listener.AbstractJmsListeningContainer.start(AbstractJmsListeningContainer.java:273)[spring-jms-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.jms.config.JmsListenerEndpointRegistry.startIfNecessary(JmsListenerEndpointRegistry.java:243)[spring-jms-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.jms.config.JmsListenerEndpointRegistry.start(JmsListenerEndpointRegistry.java:206)[spring-jms-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.context.support.DefaultLifecycleProcessor.doStart(DefaultLifecycleProcessor.java:173)[spring-context-4.3.2.RELEASE.jar:4.3.2.RELEASE] ... 12 more Caused by: javax.jms.JMSException: Could not connect to broker URL: tcp://localhost:61616. Reason: java.net.ConnectException: Connection refused: connect at org.apache.activemq.util.JMSExceptionSupport.create(JMSExceptionSupport.java:36)[activemq-client-5.13.4.jar:5.13.4] at org.apache.activemq.ActiveMQConnectionFactory.createActiveMQConnection(ActiveMQConnectionFactory.java:373)[activemq-client-5.13.4.jar:5.13.4] at org.apache.activemq.ActiveMQConnectionFactory.createActiveMQConnection(ActiveMQConnectionFactory.java:303)[activemq-client-5.13.4.jar:5.13.4] at org.apache.activemq.ActiveMQConnectionFactory.createConnection(ActiveMQConnectionFactory.java:243)[activemq-client-5.13.4.jar:5.13.4] at org.springframework.jms.support.JmsAccessor.createConnection(JmsAccessor.java:180)[spring-jms-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.jms.listener.AbstractJmsListeningContainer.createSharedConnection(AbstractJmsListeningContainer.java:413)[spring-jms-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.jms.listener.AbstractJmsListeningContainer.establishSharedConnection(AbstractJmsListeningContainer.java:381)[spring-jms-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.jms.listener.AbstractJmsListeningContainer.doStart(AbstractJmsListeningContainer.java:285)[spring-jms-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.jms.listener.SimpleMessageListenerContainer.doStart(SimpleMessageListenerContainer.java:210)[spring-jms-4.3.2.RELEASE.jar:4.3.2.RELEASE] at org.springframework.jms.listener.AbstractJmsListeningContainer.start(AbstractJmsListeningContainer.java:270)[spring-jms-4.3.2.RELEASE.jar:4.3.2.RELEASE] ... 15 more Caused by: java.net.ConnectException: Connection refused: connect at java.net.DualStackPlainSocketImpl.waitForConnect(Native Method)[na:1.8.0_92] at java.net.DualStackPlainSocketImpl.socketConnect(DualStackPlainSocketImpl.java:85)[na:1.8.0_92] at java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:350)[na:1.8.0_92] at java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:206)[na:1.8.0_92] at java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:188)[na:1.8.0_92] at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:172)[na:1.8.0_92] at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392)[na:1.8.0_92] at java.net.Socket.connect(Socket.java:589)[na:1.8.0_92] at org.apache.activemq.transport.tcp.TcpTransport.connect(TcpTransport.java:525)[activemq-client-5.13.4.jar:5.13.4] at org.apache.activemq.transport.tcp.TcpTransport.doStart(TcpTransport.java:488)[activemq-client-5.13.4.jar:5.13.4] at org.apache.activemq.util.ServiceSupport.start(ServiceSupport.java:55)[activemq-client-5.13.4.jar:5.13.4] at org.apache.activemq.transport.AbstractInactivityMonitor.start(AbstractInactivityMonitor.java:168)[activemq-client-5.13.4.jar:5.13.4] at org.apache.activemq.transport.InactivityMonitor.start(InactivityMonitor.java:52)[activemq-client-5.13.4.jar:5.13.4] at org.apache.activemq.transport.TransportFilter.start(TransportFilter.java:58)[activemq-client-5.13.4.jar:5.13.4] at org.apache.activemq.transport.WireFormatNegotiator.start(WireFormatNegotiator.java:72)[activemq-client-5.13.4.jar:5.13.4] at org.apache.activemq.transport.TransportFilter.start(TransportFilter.java:58)[activemq-client-5.13.4.jar:5.13.4] at org.apache.activemq.transport.TransportFilter.start(TransportFilter.java:58)[activemq-client-5.13.4.jar:5.13.4] at org.apache.activemq.ActiveMQConnectionFactory.createActiveMQConnection(ActiveMQConnectionFactory.java:353)[activemq-client-5.13.4.jar:5.13.4] ... 23 more

    Write tip

    You have a different solution? A short tip here would help you and many other users who saw this issue last week.

    Users with the same issue

    Once, 2 months ago
    Unknown user
    Once, 1 year ago
    Unknown user
    Once, 1 year ago
    Unknown user
    Once, 1 year ago
    Unknown user
    Once, 1 year ago
    399 more bugmates