Hi Buddhimala, Can you please describe your deployment? Single node APIM? Don't you see any errors in other throttling related scenarios? The exception says APIM can't open connection through 5672. Were you able to telnet to that port?
On Thu, Nov 23, 2017 at 1:23 PM, Buddhimala Ranasinghe <buddhim...@wso2.com> wrote: > Hi All, > > I followed the link https://wso2.com/library/demonstrations/2016/11/ > screencast-defining-advanced-throttling-policies-in-wso2-api-manager/ to > perform IP based throttling for my API. But when I invoke the service, I > get the following error in APIM logs. > > INFO - JMSConnectionFactory JMS ConnectionFactory : jmsEventPublisher > initialized > [2017-11-23 12:45:48,036] INFO - AMQConnection Unable to connect to > broker at tcp://localhost:5672 > org.wso2.andes.transport.TransportException: Could not open connection > at org.wso2.andes.transport.network.mina.MinaNetworkTransport$ > IoConnectorCreator.connect(MinaNetworkTransport.java:216) > at org.wso2.andes.transport.network.mina.MinaNetworkTransport.connect( > MinaNetworkTransport.java:74) > at org.wso2.andes.client.AMQConnectionDelegate_8_0. > makeBrokerConnection(AMQConnectionDelegate_8_0.java:130) > at org.wso2.andes.client.AMQConnection$2.run(AMQConnection.java:631) > at org.wso2.andes.client.AMQConnection$2.run(AMQConnection.java:628) > at java.security.AccessController.doPrivileged(Native Method) > at org.wso2.andes.client.AMQConnection.makeBrokerConnection( > AMQConnection.java:628) > at org.wso2.andes.client.AMQConnection.<init>(AMQConnection.java:409) > at org.wso2.andes.client.AMQConnectionFactory.createConnection( > AMQConnectionFactory.java:351) > at org.wso2.andes.client.AMQConnectionFactory.createConnection( > AMQConnectionFactory.java:40) > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSUtils.createConnection(JMSUtils.java:387) > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSConnectionFactory.createConnection(JMSConnectionFactory.java:268) > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSConnectionFactory$PoolableJMSConnectionFactory.makeObject( > JMSConnectionFactory.java:356) > at org.apache.commons.pool.impl.GenericObjectPool.borrowObject( > GenericObjectPool.java:1181) > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSConnectionFactory.getConnectionFromPool(JMSConnectionFactory.java:286) > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSMessageSender.send(JMSMessageSender.java:86) > at org.wso2.carbon.event.output.adapter.jms.JMSEventAdapter$ > JMSSender.run(JMSEventAdapter.java:284) > at java.util.concurrent.Executors$RunnableAdapter. > call(Executors.java:511) > at java.util.concurrent.FutureTask.run(FutureTask.java:266) > at java.util.concurrent.ThreadPoolExecutor.runWorker( > ThreadPoolExecutor.java:1142) > at java.util.concurrent.ThreadPoolExecutor$Worker.run( > ThreadPoolExecutor.java:617) > at java.lang.Thread.run(Thread.java:748) > org.wso2.andes.AMQConnectionFailureException: Could not open connection > at org.wso2.andes.client.AMQConnection.<init>(AMQConnection.java:486) > at org.wso2.andes.client.AMQConnectionFactory.createConnection( > AMQConnectionFactory.java:351) > at org.wso2.andes.client.AMQConnectionFactory.createConnection( > AMQConnectionFactory.java:40) > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSUtils.createConnection(JMSUtils.java:387) > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSConnectionFactory.createConnection(JMSConnectionFactory.java:268) > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSConnectionFactory$PoolableJMSConnectionFactory.makeObject( > JMSConnectionFactory.java:356) > at org.apache.commons.pool.impl.GenericObjectPool.borrowObject( > GenericObjectPool.java:1181) > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSConnectionFactory.getConnectionFromPool(JMSConnectionFactory.java:286) > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSMessageSender.send(JMSMessageSender.java:86) > at org.wso2.carbon.event.output.adapter.jms.JMSEventAdapter$ > JMSSender.run(JMSEventAdapter.java:284) > at java.util.concurrent.Executors$RunnableAdapter. > call(Executors.java:511) > at java.util.concurrent.FutureTask.run(FutureTask.java:266) > at java.util.concurrent.ThreadPoolExecutor.runWorker( > ThreadPoolExecutor.java:1142) > at java.util.concurrent.ThreadPoolExecutor$Worker.run( > ThreadPoolExecutor.java:617) > at java.lang.Thread.run(Thread.java:748) > Caused by: org.wso2.andes.transport.TransportException: Could not open > connection > at org.wso2.andes.transport.network.mina.MinaNetworkTransport$ > IoConnectorCreator.connect(MinaNetworkTransport.java:216) > at org.wso2.andes.transport.network.mina.MinaNetworkTransport.connect( > MinaNetworkTransport.java:74) > at org.wso2.andes.client.AMQConnectionDelegate_8_0. > makeBrokerConnection(AMQConnectionDelegate_8_0.java:130) > at org.wso2.andes.client.AMQConnection$2.run(AMQConnection.java:631) > at org.wso2.andes.client.AMQConnection$2.run(AMQConnection.java:628) > at java.security.AccessController.doPrivileged(Native Method) > at org.wso2.andes.client.AMQConnection.makeBrokerConnection( > AMQConnection.java:628) > at org.wso2.andes.client.AMQConnection.<init>(AMQConnection.java:409) > ... 14 more > [2017-11-23 12:45:48,039] ERROR - JMSConnectionFactory Error acquiring a > Connection from the JMS CF : jmsEventPublisher using properties : > {transport.jms.ConcurrentPublishers=allow, java.naming.provider.url= > repository/conf/jndi.properties, java.naming.factory.initial= > org.wso2.andes.jndi.PropertiesFileInitialContextFactory, > transport.jms.DestinationType=topic, transport.jms. > ConnectionFactoryJNDIName=TopicConnectionFactory, > transport.jms.Destination=throttleData} > javax.jms.JMSException: Error creating connection: Could not open > connection > at org.wso2.andes.client.AMQConnectionFactory.createConnection( > AMQConnectionFactory.java:361) > at org.wso2.andes.client.AMQConnectionFactory.createConnection( > AMQConnectionFactory.java:40) > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSUtils.createConnection(JMSUtils.java:387) > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSConnectionFactory.createConnection(JMSConnectionFactory.java:268) > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSConnectionFactory$PoolableJMSConnectionFactory.makeObject( > JMSConnectionFactory.java:356) > at org.apache.commons.pool.impl.GenericObjectPool.borrowObject( > GenericObjectPool.java:1181) > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSConnectionFactory.getConnectionFromPool(JMSConnectionFactory.java:286) > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSMessageSender.send(JMSMessageSender.java:86) > at org.wso2.carbon.event.output.adapter.jms.JMSEventAdapter$ > JMSSender.run(JMSEventAdapter.java:284) > at java.util.concurrent.Executors$RunnableAdapter. > call(Executors.java:511) > at java.util.concurrent.FutureTask.run(FutureTask.java:266) > at java.util.concurrent.ThreadPoolExecutor.runWorker( > ThreadPoolExecutor.java:1142) > at java.util.concurrent.ThreadPoolExecutor$Worker.run( > ThreadPoolExecutor.java:617) > at java.lang.Thread.run(Thread.java:748) > Caused by: org.wso2.andes.AMQConnectionFailureException: Could not open > connection > at org.wso2.andes.client.AMQConnection.<init>(AMQConnection.java:486) > at org.wso2.andes.client.AMQConnectionFactory.createConnection( > AMQConnectionFactory.java:351) > ... 13 more > Caused by: org.wso2.andes.transport.TransportException: Could not open > connection > at org.wso2.andes.transport.network.mina.MinaNetworkTransport$ > IoConnectorCreator.connect(MinaNetworkTransport.java:216) > at org.wso2.andes.transport.network.mina.MinaNetworkTransport.connect( > MinaNetworkTransport.java:74) > at org.wso2.andes.client.AMQConnectionDelegate_8_0. > makeBrokerConnection(AMQConnectionDelegate_8_0.java:130) > at org.wso2.andes.client.AMQConnection$2.run(AMQConnection.java:631) > at org.wso2.andes.client.AMQConnection$2.run(AMQConnection.java:628) > at java.security.AccessController.doPrivileged(Native Method) > at org.wso2.andes.client.AMQConnection.makeBrokerConnection( > AMQConnection.java:628) > at org.wso2.andes.client.AMQConnection.<init>(AMQConnection.java:409) > ... 14 more > [2017-11-23 12:45:48,040] ERROR - JMSConnectionFactory Error acquiring a > Connection from the JMS CF : jmsEventPublisher using properties : > {transport.jms.ConcurrentPublishers=allow, java.naming.provider.url= > repository/conf/jndi.properties, java.naming.factory.initial= > org.wso2.andes.jndi.PropertiesFileInitialContextFactory, > transport.jms.DestinationType=topic, transport.jms. > ConnectionFactoryJNDIName=TopicConnectionFactory, > transport.jms.Destination=throttleData} > org.wso2.carbon.event.output.adapter.core.exception. > OutputEventAdapterRuntimeException: Error acquiring a Connection from the > JMS CF : jmsEventPublisher using properties : > {transport.jms.ConcurrentPublishers=allow, > java.naming.provider.url=repository/conf/jndi.properties, > java.naming.factory.initial=org.wso2.andes.jndi. > PropertiesFileInitialContextFactory, transport.jms.DestinationType=topic, > transport.jms.ConnectionFactoryJNDIName=TopicConnectionFactory, > transport.jms.Destination=throttleData} > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSConnectionFactory.handleException(JMSConnectionFactory.java:197) > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSConnectionFactory.createConnection(JMSConnectionFactory.java:278) > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSConnectionFactory$PoolableJMSConnectionFactory.makeObject( > JMSConnectionFactory.java:356) > at org.apache.commons.pool.impl.GenericObjectPool.borrowObject( > GenericObjectPool.java:1181) > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSConnectionFactory.getConnectionFromPool(JMSConnectionFactory.java:286) > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSMessageSender.send(JMSMessageSender.java:86) > at org.wso2.carbon.event.output.adapter.jms.JMSEventAdapter$ > JMSSender.run(JMSEventAdapter.java:284) > at java.util.concurrent.Executors$RunnableAdapter. > call(Executors.java:511) > at java.util.concurrent.FutureTask.run(FutureTask.java:266) > at java.util.concurrent.ThreadPoolExecutor.runWorker( > ThreadPoolExecutor.java:1142) > at java.util.concurrent.ThreadPoolExecutor$Worker.run( > ThreadPoolExecutor.java:617) > at java.lang.Thread.run(Thread.java:748) > Caused by: javax.jms.JMSException: Error creating connection: Could not > open connection > at org.wso2.andes.client.AMQConnectionFactory.createConnection( > AMQConnectionFactory.java:361) > at org.wso2.andes.client.AMQConnectionFactory.createConnection( > AMQConnectionFactory.java:40) > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSUtils.createConnection(JMSUtils.java:387) > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSConnectionFactory.createConnection(JMSConnectionFactory.java:268) > ... 10 more > Caused by: org.wso2.andes.AMQConnectionFailureException: Could not open > connection > at org.wso2.andes.client.AMQConnection.<init>(AMQConnection.java:486) > at org.wso2.andes.client.AMQConnectionFactory.createConnection( > AMQConnectionFactory.java:351) > ... 13 more > Caused by: org.wso2.andes.transport.TransportException: Could not open > connection > at org.wso2.andes.transport.network.mina.MinaNetworkTransport$ > IoConnectorCreator.connect(MinaNetworkTransport.java:216) > at org.wso2.andes.transport.network.mina.MinaNetworkTransport.connect( > MinaNetworkTransport.java:74) > at org.wso2.andes.client.AMQConnectionDelegate_8_0. > makeBrokerConnection(AMQConnectionDelegate_8_0.java:130) > at org.wso2.andes.client.AMQConnection$2.run(AMQConnection.java:631) > at org.wso2.andes.client.AMQConnection$2.run(AMQConnection.java:628) > at java.security.AccessController.doPrivileged(Native Method) > at org.wso2.andes.client.AMQConnection.makeBrokerConnection( > AMQConnection.java:628) > at org.wso2.andes.client.AMQConnection.<init>(AMQConnection.java:409) > ... 14 more > [2017-11-23 12:45:48,041] ERROR - JMSMessageSender > java.lang.NullPointerException > at org.wso2.carbon.event.output.adapter.jms.internal.util. > JMSMessageSender.send(JMSMessageSender.java:88) > at org.wso2.carbon.event.output.adapter.jms.JMSEventAdapter$ > JMSSender.run(JMSEventAdapter.java:284) > at java.util.concurrent.Executors$RunnableAdapter. > call(Executors.java:511) > at java.util.concurrent.FutureTask.run(FutureTask.java:266) > at java.util.concurrent.ThreadPoolExecutor.runWorker( > ThreadPoolExecutor.java:1142) > at java.util.concurrent.ThreadPoolExecutor$Worker.run( > ThreadPoolExecutor.java:617) > at java.lang.Thread.run(Thread.java:748) > > How can I resolve this problem? Your support is highly appreciated. > > Thanks > -- > > > *Buddhimala Ranasinghe* > Software Engineer-Support Team | WSO2 > Emil: buddhim...@wso2.com > Mobile:+94771563138 <+94%2077%20156%203138> > Web:http://wso2.com > [image: https://wso2.com/signature] <https://wso2.com/signature> > > _______________________________________________ > Dev mailing list > Dev@wso2.org > http://wso2.org/cgi-bin/mailman/listinfo/dev > > -- Thanks Abimaran Kugathasan Senior Software Engineer - API Technologies Email : abima...@wso2.com Mobile : +94 773922820 <http://stackoverflow.com/users/515034> <http://lk.linkedin.com/in/abimaran> <http://www.lkabimaran.blogspot.com/> <https://github.com/abimarank> <https://twitter.com/abimaran>
_______________________________________________ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev