uima-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nelson rivera <nelsonriver...@gmail.com>
Subject Re: How know when "Session is closed" after establish connections between uima-as client and ActiveMQ?
Date Mon, 10 Jul 2017 19:51:33 GMT
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(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-07 15:33 GMT-04:00, nelson rivera <nelsonrivera12@gmail.com>:
> 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 <cwiklik@apache.org>:
>> 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 <cwiklik@apache.org>
>> 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 <nelsonrivera12@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 <cwiklik@apache.org>:
>>>> > 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 <cwiklik@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 <
>>>> nelsonrivera12@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)
>>>> >>>
>>>> >>> 2017-07-05 12:16 GMT-04:00, nelson rivera
>>>> >>> <nelsonrivera12@gmail.com>:
>>>> >>> > This behavior is random, not occurs always. In the most
of the
>>>> simple
>>>> >>> > programs and simple test case tested, after restart the
UIMA-AS
>>>> Broker
>>>> >>> > without restart service uima-as, the instruccion to uima-as
>>>> >>> > client
>>>> >>> > "BaseUIMAAsynchronousEngine_impl.connectionOpen()" return
"false"
>>>> and
>>>> >>> > correctly i initialize the client again.
>>>> >>> >
>>>> >>> > The incorrect behavior is most frequently with many uima-as
>>>> >>> > client
>>>> >>> > instances. Is the case of my general application in which
i have
>>>> many
>>>> >>> > service uima-as, and for each one creates one instace of
uima-as
>>>> >>> > client (BaseUIMAAsynchronousEngine_impl) and keep it alive
to
>>>> process
>>>> >>> > all requests of the service uima-as.
>>>> >>> >
>>>> >>> > Is in this scenario with many instancies of uima-as client
>>>> >>> > (BaseUIMAAsynchronousEngine_impl) in the same program (a
>>>> >>> > monolithic
>>>> >>> > application web in tomcat) where after restart the UIMA-AS
Broker
>>>> >>> > without restart any service uima-as, many uima-as client
returns
>>>> >>> > "true" to the instruccion
>>>> >>> > "BaseUIMAAsynchronousEngine_impl.connectionOpen()" but
them throw
>>>> >>> > "javax.jms.IllegalStateException: The Session is closed"
>>>> >>> > when proces the request.
>>>> >>> >
>>>> >>> > 2017-07-04 16:13 GMT-04:00, nelson rivera
>>>> >>> > <nelsonrivera12@gmail.com
>>>> >:
>>>> >>> >> One peculiarity is that, is a primitive annotator implented
in
>>>> >>> >> c++,
>>>> >>> >> but is deployed with de deployAsyncService.sh de uima-as
>>>> >>> >> directly.
>>>> >>> >>
>>>> >>> >> 2017-07-04 14:53 GMT-04:00, nelson rivera <
>>>> nelsonrivera12@gmail.com>:
>>>> >>> >>> In my program main, i initialize a uimas-as client
only once
>>>> >>> >>> and
>>>> >>> >>> I
>>>> >>> >>> use
>>>> >>> >>> this client to consume all requests to a displayed
service
>>>> uima-as.
>>>> >>> >>>
>>>> >>> >>> Before process a request i ask to uima-as client
with:
>>>> >>> >>> BaseUIMAAsynchronousEngine_impl.connectionOpen()
>>>> >>> >>> and if the result es "false", i stop the uima-as
client and
>>>> >>> >>> initialize
>>>> >>> >>> it
>>>> >>> >>> again.
>>>> >>> >>>
>>>> >>> >>> With some steps, still undefined, but after restart
the UIMA-AS
>>>> >>> >>> Broker
>>>> >>> >>> without restart service uima-as.
>>>> >>> >>> The instruccion to uima-as client
>>>> >>> >>> BaseUIMAAsynchronousEngine_impl.connectionOpen()
return "true",
>>>> but
>>>> >>> >>> them i get a "javax.jms.IllegalStateException:
The Session is
>>>> >>> >>> closed"
>>>> >>> >>> when proces the request.
>>>> >>> >>>
>>>> >>> >>> Wich is the best way to know when connections betewen
cliente
>>>> >>> >>> uima-as
>>>> >>> >>> and ActiveMQ is broken? and i should restart uima-as
client.
>>>> >>> >>>
>>>> >>> >>
>>>> >>> >
>>>> >>>
>>>> >>
>>>> >>
>>>> >
>>>>
>>>
>>>
>>
>

Mime
View raw message