Re: How know when "Session is closed" after establish connections between uima-as client and ActiveMQ?
Thanks very much, actually i have my application in production but with this bug as reported. i wait 2017-07-11 9:59 GMT-04:00, Jaroslaw Cwiklik: > Hi, I am investigating this issue now. Are you having this problem in > production or testing? The multi-client recovery is quite complicated and > subject to race conditions. I need to first re-create the problem and work > on a solution if this in fact is a bug. From what you sent it looks like > there is a bug in client recovery. This may take some time to sort out. > Will let you know what I find. > > Jerry > > On Tue, Jul 11, 2017 at 9:02 AM, nelson rivera > wrote: > >> analyzing more deep the issue, I have observed that after restart the >> broker, the first uima-as client that is consumed (no matter which), >> has a correct behavior, the instruccion to uima-as client >> "BaseUIMAAsynchronousEngine_impl.connectionOpen()" return "false" and >> correctly initializes the client again and process the request. >> >> All next uima-as client to consume returns "true" to the instruccion >> "BaseUIMAAsynchronousEngine_impl.connectionOpen()" and them get the >> error: >> >> jul 11, 2017 8:11:52 AM >> org.apache.uima.adapter.jms.client.ActiveMQMessageSender createSession >> INFORMACIÓN: UIMA AS Client Failed Creating Session To Destination: >> XCharsetDetector Managed By Broker: tcp://nelson-XPS-8700:61616 >> jul 11, 2017 8:11:52 AM >> org.apache.uima.adapter.jms.client.ActiveMQMessageSender createSession >> INFORMACIÓN: UIMA AS Client Connection To Destination: >> XCharsetDetector Managed By Broker: tcp://nelson-XPS-8700:61616 Is >> Closed >> jul 11, 2017 8:11:52 AM >> org.apache.uima.adapter.jms.client.ActiveMQMessageSender run >> ADVERTENCIA: >> org.apache.activemq.ConnectionClosedException: The connection is already >> closed >> at org.apache.activemq.ActiveMQConnection.checkClosed( >> ActiveMQConnection.java:1459) >> at org.apache.activemq.ActiveMQConnection.checkClosedOrFailed( >> ActiveMQConnection.java:1446) >> at org.apache.activemq.ActiveMQConnection.createSession( >> ActiveMQConnection.java:328) >> at org.apache.uima.adapter.jms.client.ActiveMQMessageSender. >> createSession(ActiveMQMessageSender.java:108) >> at org.apache.uima.adapter.jms.client.ActiveMQMessageSender. >> initializeProducer(ActiveMQMessageSender.java:143) >> at org.apache.uima.adapter.jms.client.ActiveMQMessageSender. >> createTextMessage(ActiveMQMessageSender.java:191) >> at org.apache.uima.adapter.jms.client.BaseMessageSender.run( >> BaseMessageSender.java:330) >> at java.lang.Thread.run(Thread.java:748) >> >> 2017-07-11 8:50 GMT-04:00, nelson rivera : >> > My client application not receive any exception in any time. I use >> > both, in some uima-as client use sendAndReceive() and in others use >> > send(), each uima-as client has try-catch and none of them receive a >> > exception, the following lines are printed in the console output,but >> > the uima-as client is not notified and keeps waiting. >> > >> > 2017-07-10 16:48 GMT-04:00, Jaroslaw Cwiklik : >> >> it looks like the UIMA-AS client is setup to throw an exception back >> >> to >> >> the >> >> application in this case. Did your application receive an exception? >> >> Are >> >> you using sendAndReceive() or send()? The UIMA-AS client rejects >> requests >> >> while a connection is down. >> >> >> >> Jerry >> >> >> >> On Mon, Jul 10, 2017 at 4:19 PM, Jaroslaw Cwiklik >> >> wrote: >> >> >> >>> Hmm, this is a different exception from Session closed. This time it >> >>> is >> >>> a >> >>> Connection is closed. Seems like a race condition. How many UIMA-AS >> >>> clients >> >>> do you have running in this process? >> >>> >> >>> Jerry >> >>> >> >>> On Mon, Jul 10, 2017 at 3:51 PM, nelson rivera >> >>> >> >>> wrote: >> >>> >> i just tested the snapshot build from >> https://svn.apache.org/repos/asf/uima/uima-as/trunk, and the >> behavior >> still are similar for many uima-as client, end in a exception, but >> now >> show this stacktrace: >> >> org.apache.activemq.ConnectionClosedException: The connection is >> already >> closed >> at org.apache.activemq.ActiveMQConnection. >> checkClosed(ActiveMQC >> onnection.java:1459) >> at org.apache.activemq.ActiveMQConnection. >> checkClosedOrFailed(A >> ctiveMQConnection.java:1446) >> at org.apache.activemq.ActiveMQConnection. >> createSession(ActiveM >> QConnection.java:328) >> at org.apache.uima.adapter.jms.client.ActiveMQMessageSender. >> cre >> ateSession(ActiveMQMessageSender.java:108) >> at org.apache.uima.adapter.jms.client.ActiveMQMessageSender. >> ini >> tializeProducer(ActiveMQMessageSender.java:143) >> at
Re: How know when "Session is closed" after establish connections between uima-as client and ActiveMQ?
Hi, I am investigating this issue now. Are you having this problem in production or testing? The multi-client recovery is quite complicated and subject to race conditions. I need to first re-create the problem and work on a solution if this in fact is a bug. From what you sent it looks like there is a bug in client recovery. This may take some time to sort out. Will let you know what I find. Jerry On Tue, Jul 11, 2017 at 9:02 AM, nelson riverawrote: > analyzing more deep the issue, I have observed that after restart the > broker, the first uima-as client that is consumed (no matter which), > has a correct behavior, the instruccion to uima-as client > "BaseUIMAAsynchronousEngine_impl.connectionOpen()" return "false" and > correctly initializes the client again and process the request. > > All next uima-as client to consume returns "true" to the instruccion > "BaseUIMAAsynchronousEngine_impl.connectionOpen()" and them get the error: > > jul 11, 2017 8:11:52 AM > org.apache.uima.adapter.jms.client.ActiveMQMessageSender createSession > INFORMACIÓN: UIMA AS Client Failed Creating Session To Destination: > XCharsetDetector Managed By Broker: tcp://nelson-XPS-8700:61616 > jul 11, 2017 8:11:52 AM > org.apache.uima.adapter.jms.client.ActiveMQMessageSender createSession > INFORMACIÓN: UIMA AS Client Connection To Destination: > XCharsetDetector Managed By Broker: tcp://nelson-XPS-8700:61616 Is > Closed > jul 11, 2017 8:11:52 AM > org.apache.uima.adapter.jms.client.ActiveMQMessageSender run > ADVERTENCIA: > org.apache.activemq.ConnectionClosedException: The connection is already > closed > at org.apache.activemq.ActiveMQConnection.checkClosed( > ActiveMQConnection.java:1459) > at org.apache.activemq.ActiveMQConnection.checkClosedOrFailed( > ActiveMQConnection.java:1446) > at org.apache.activemq.ActiveMQConnection.createSession( > ActiveMQConnection.java:328) > at org.apache.uima.adapter.jms.client.ActiveMQMessageSender. > createSession(ActiveMQMessageSender.java:108) > at org.apache.uima.adapter.jms.client.ActiveMQMessageSender. > initializeProducer(ActiveMQMessageSender.java:143) > at org.apache.uima.adapter.jms.client.ActiveMQMessageSender. > createTextMessage(ActiveMQMessageSender.java:191) > at org.apache.uima.adapter.jms.client.BaseMessageSender.run( > BaseMessageSender.java:330) > at java.lang.Thread.run(Thread.java:748) > > 2017-07-11 8:50 GMT-04:00, nelson rivera : > > My client application not receive any exception in any time. I use > > both, in some uima-as client use sendAndReceive() and in others use > > send(), each uima-as client has try-catch and none of them receive a > > exception, the following lines are printed in the console output,but > > the uima-as client is not notified and keeps waiting. > > > > 2017-07-10 16:48 GMT-04:00, Jaroslaw Cwiklik : > >> it looks like the UIMA-AS client is setup to throw an exception back to > >> the > >> application in this case. Did your application receive an exception? Are > >> you using sendAndReceive() or send()? The UIMA-AS client rejects > requests > >> while a connection is down. > >> > >> Jerry > >> > >> On Mon, Jul 10, 2017 at 4:19 PM, Jaroslaw Cwiklik > >> wrote: > >> > >>> Hmm, this is a different exception from Session closed. This time it is > >>> a > >>> Connection is closed. Seems like a race condition. How many UIMA-AS > >>> clients > >>> do you have running in this process? > >>> > >>> Jerry > >>> > >>> On Mon, Jul 10, 2017 at 3:51 PM, nelson rivera > >>> > >>> wrote: > >>> > i just tested the snapshot build from > https://svn.apache.org/repos/asf/uima/uima-as/trunk, and the behavior > still are similar for many uima-as client, end in a exception, but now > show this stacktrace: > > org.apache.activemq.ConnectionClosedException: The connection is > already > closed > at org.apache.activemq.ActiveMQConnection. > checkClosed(ActiveMQC > onnection.java:1459) > at org.apache.activemq.ActiveMQConnection. > checkClosedOrFailed(A > ctiveMQConnection.java:1446) > at org.apache.activemq.ActiveMQConnection. > createSession(ActiveM > QConnection.java:328) > at org.apache.uima.adapter.jms.client.ActiveMQMessageSender. > cre > ateSession(ActiveMQMessageSender.java:108) > at org.apache.uima.adapter.jms.client.ActiveMQMessageSender. > ini > tializeProducer(ActiveMQMessageSender.java:143) > at org.apache.uima.adapter.jms.client.ActiveMQMessageSender. > cre > ateTextMessage(ActiveMQMessageSender.java:191) > at org.apache.uima.adapter.jms.client.BaseMessageSender.run( > Bas > eMessageSender.java:330) > at java.lang.Thread.run(Thread.java:748) > > 2017-07-07 15:33 GMT-04:00, nelson rivera
Re: How know when "Session is closed" after establish connections between uima-as client and ActiveMQ?
My client application not receive any exception in any time. I use both, in some uima-as client use sendAndReceive() and in others use send(), each uima-as client has try-catch and none of them receive a exception, the following lines are printed in the console output,but the uima-as client is not notified and keeps waiting. 2017-07-10 16:48 GMT-04:00, Jaroslaw Cwiklik: > it looks like the UIMA-AS client is setup to throw an exception back to the > application in this case. Did your application receive an exception? Are > you using sendAndReceive() or send()? The UIMA-AS client rejects requests > while a connection is down. > > Jerry > > On Mon, Jul 10, 2017 at 4:19 PM, Jaroslaw Cwiklik > wrote: > >> Hmm, this is a different exception from Session closed. This time it is a >> Connection is closed. Seems like a race condition. How many UIMA-AS >> clients >> do you have running in this process? >> >> Jerry >> >> On Mon, Jul 10, 2017 at 3:51 PM, nelson rivera >> wrote: >> >>> i just tested the snapshot build from >>> https://svn.apache.org/repos/asf/uima/uima-as/trunk, and the behavior >>> still are similar for many uima-as client, end in a exception, but now >>> show this stacktrace: >>> >>> org.apache.activemq.ConnectionClosedException: The connection is already >>> closed >>> at org.apache.activemq.ActiveMQConnection.checkClosed(ActiveMQC >>> onnection.java:1459) >>> at org.apache.activemq.ActiveMQConnection.checkClosedOrFailed(A >>> ctiveMQConnection.java:1446) >>> at org.apache.activemq.ActiveMQConnection.createSession(ActiveM >>> QConnection.java:328) >>> at org.apache.uima.adapter.jms.client.ActiveMQMessageSender.cre >>> ateSession(ActiveMQMessageSender.java:108) >>> at org.apache.uima.adapter.jms.client.ActiveMQMessageSender.ini >>> tializeProducer(ActiveMQMessageSender.java:143) >>> at org.apache.uima.adapter.jms.client.ActiveMQMessageSender.cre >>> ateTextMessage(ActiveMQMessageSender.java:191) >>> at org.apache.uima.adapter.jms.client.BaseMessageSender.run(Bas >>> eMessageSender.java:330) >>> at java.lang.Thread.run(Thread.java:748) >>> >>> 2017-07-07 15:33 GMT-04:00, nelson rivera : >>> > Sorry for the delay, i am building the framework from the source at >>> > https://svn.apache.org/repos/asf/uima/uima-as/trunk, when test the >>> > issue, i will comment the result. >>> > >>> > 2017-07-06 10:04 GMT-04:00, Jaroslaw Cwiklik : >>> >> Hello, the snapshot binaries (zip + tar) are here: >>> >> >>> >> https://repository.apache.org/content/repositories/snapshots >>> /org/apache/uima/uima-as/2.9.1-SNAPSHOT/ >>> >> >>> >> Jerry >>> >> >>> >> On Thu, Jul 6, 2017 at 8:51 AM, Jaroslaw Cwiklik >>> >> wrote: >>> >> >>> >>> Hi, instructions how to build from source are here: >>> >>> https://uima.apache.org/building-uima.html >>> >>> >>> >>> It's a bit involved process so I will try to post a snapshot of >>> uima-as >>> >>> to >>> >>> Apache snapshot repository and will provide you with a link later >>> today. >>> >>> >>> >>> Jerry >>> >>> >>> >>> On Wed, Jul 5, 2017 at 4:32 PM, nelson rivera < >>> nelsonriver...@gmail.com> >>> >>> wrote: >>> >>> >>> Please can you give me the url to source code with the changes, to >>> test. >>> >>> 2017-07-05 16:19 GMT-04:00, Jaroslaw Cwiklik : >>> > Just delivered a few changes to deal with a stale Session. Can >>> > you >>> > build >>> > from source and test. >>> > Jerry >>> > >>> > On Wed, Jul 5, 2017 at 2:21 PM, Jaroslaw Cwiklik < >>> cwik...@apache.org> >>> > wrote: >>> > >>> >> Thanks. Will check the code and work on a fix >>> >> >>> >> Jerry >>> >> >>> >> On Wed, Jul 5, 2017 at 2:10 PM, nelson rivera < >>> nelsonriver...@gmail.com> >>> >> wrote: >>> >> >>> >>> Here the stack trace for the error that asked me: >>> >>> jul 05, 2017 2:08:50 PM >>> >>> org.apache.uima.adapter.jms.client.ActiveMQMessageSender run >>> >>> ADVERTENCIA: >>> >>> javax.jms.IllegalStateException: The Session is closed >>> >>> at org.apache.activemq.ActiveMQSe >>> ssion.checkClosed(ActiveMQSess >>> >>> ion.java:771) >>> >>> at org.apache.activemq.ActiveMQSe >>> ssion.configureMessage(ActiveM >>> >>> QSession.java:759) >>> >>> at org.apache.activemq.ActiveMQSe >>> ssion.createTextMessage(Active >>> >>> MQSession.java:440) >>> >>> at org.apache.uima.adapter.jms.cl >>> ient.ActiveMQMessageSender.cre >>> >>> ateTextMessage(ActiveMQMessageSender.java:184) >>> >>> at org.apache.uima.adapter.jms.cl >>> ient.BaseMessageSender.run(Bas >>> >>> eMessageSender.java:307) >>> >>> at java.lang.Thread.run(Thread.java:748) >>> >>> >>>