Hi Lahiru, I beleive that these thrift publishing and application event publishing are two threads..Application event publishing is not using any thrift. This thrift exception is coming from some other thread which tries to publish data.
Thanks, Reka On Thu, Dec 11, 2014 at 1:53 PM, Udara Liyanage <ud...@wso2.com> wrote: > Hi Akila, > > I think what Lahiru meant is why it is using thrift to publish events > > On Thu, Dec 11, 2014 at 1:49 PM, Akila Ravihansa Perera < > raviha...@wso2.com> wrote: > >> Hi Lahiru, >> >> Try setting the hostname to 0.0.0.0 in >> repository\conf\data-bridge\data-bridge-config.xml >> >> <thriftDataReceiver> >> <hostName>0.0.0.0</hostName> >> <port>7611</port> >> <securePort>7711</securePort> >> </thriftDataReceiver> >> >> This will bind the thrift agent to any IP address, >> >> Thanks. >> >> On Thu, Dec 11, 2014 at 8:09 AM, Lahiru Sandaruwan <lahi...@wso2.com> >> wrote: >> >>> Hi, >>> >>> I see following error while Autoscaler trying to send an event. Any idea >>> why it is trying to use thrift? >>> >>> [2014-12-11 08:04:39,918] INFO >>> {org.apache.stratos.autoscaler.applications.topic.ApplicationsEventPublisher} >>> - Publishing Application In-activated event for [application]: >>> app_cartridge_v1 >>> >>> [2014-12-11 08:04:50,382] ERROR >>> {org.wso2.carbon.databridge.agent.thrift.AsyncDataPublisher} - Error while >>> connection to event receiver >>> >>> org.wso2.carbon.databridge.agent.thrift.exception.AgentException: Cannot >>> borrow client for TCP,localhost:7611,TCP,localhost:7711 >>> >>> at >>> org.wso2.carbon.databridge.agent.thrift.internal.publisher.authenticator.AgentAuthenticator.connect(AgentAuthenticator.java:58) >>> >>> at >>> org.wso2.carbon.databridge.agent.thrift.DataPublisher.start(DataPublisher.java:273) >>> >>> at >>> org.wso2.carbon.databridge.agent.thrift.DataPublisher.<init>(DataPublisher.java:161) >>> >>> at >>> org.wso2.carbon.databridge.agent.thrift.AsyncDataPublisher$ReceiverConnectionWorker.run(AsyncDataPublisher.java:787) >>> >>> at >>> java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471) >>> >>> at java.util.concurrent.FutureTask.run(FutureTask.java:262) >>> >>> at >>> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) >>> >>> at >>> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) >>> >>> at java.lang.Thread.run(Thread.java:745) >>> >>> Caused by: org.apache.thrift.transport.TTransportException: Could not >>> connect to 172.16.2.98 on port 7711 >>> >>> at >>> org.apache.thrift.transport.TSSLTransportFactory.createClient(TSSLTransportFactory.java:212) >>> >>> at >>> org.apache.thrift.transport.TSSLTransportFactory.getClientSocket(TSSLTransportFactory.java:166) >>> >>> at >>> org.wso2.carbon.databridge.agent.thrift.internal.pool.client.secure.SecureClientPoolFactory.makeObject(SecureClientPoolFactory.java:90) >>> >>> at >>> org.wso2.carbon.databridge.agent.thrift.internal.pool.client.secure.SecureClientPoolFactory.makeObject(SecureClientPoolFactory.java:48) >>> >>> at >>> org.apache.commons.pool.impl.GenericKeyedObjectPool.borrowObject(GenericKeyedObjectPool.java:1212) >>> >>> at >>> org.wso2.carbon.databridge.agent.thrift.internal.publisher.authenticator.AgentAuthenticator.connect(AgentAuthenticator.java:50) >>> >>> ... 8 more >>> >>> Caused by: java.net.ConnectException: Operation timed out >>> >>> at java.net.PlainSocketImpl.socketConnect(Native Method) >>> >>> at >>> java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:339) >>> >>> at >>> java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:200) >>> >>> at >>> java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:182) >>> >>> at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392) >>> >>> at java.net.Socket.connect(Socket.java:579) >>> Thanks. >>> -- >>> -- >>> Lahiru Sandaruwan >>> Committer and PMC member, Apache Stratos, >>> Senior Software Engineer, >>> WSO2 Inc., http://wso2.com >>> lean.enterprise.middleware >>> >>> email: lahi...@wso2.com blog: http://lahiruwrites.blogspot.com/ >>> linked-in: http://lk.linkedin.com/pub/lahiru-sandaruwan/16/153/146 >>> >>> >> >> >> -- >> Akila Ravihansa Perera >> Software Engineer, WSO2 >> >> Blog: http://ravihansa3000.blogspot.com >> > > > > -- > > Udara Liyanage > Software Engineer > WSO2, Inc.: http://wso2.com > lean. enterprise. middleware > > web: http://udaraliyanage.wordpress.com > phone: +94 71 443 6897 > -- Reka Thirunavukkarasu Senior Software Engineer, WSO2, Inc.:http://wso2.com, Mobile: +94776442007