Re: Artemis v2.2: ActiveMQIllegalStateException with core API

2017-08-29 Thread Marko Asplund
The exceptions don't seem to be related with consumers closing. Unfortunately, I haven't been able to see a pattern, yet, so I don't have code for reproducing the issue. marko On Fri, 25 Aug 2017 16:49:40 GMT Clebert Suconic wrote: > so, you're seeing this when you close the consumer? > > Perha

Re: Artemis v2.2: ActiveMQIllegalStateException with core API

2017-08-29 Thread Marko Asplund
On Thu, 24 Aug 2017 13:46:27 GMT Justin Bertram wrote: > I would do this: > > 1) Invoke org.apache.activemq.artemis.api.core.client.ClientSession#stop > 2) Invoke org.apache.activemq.artemis.api.core.client.ClientConsumer#close > ... I just changed the code to close the consumer after closing

Re: Artemis v2.2: ActiveMQIllegalStateException with core API

2017-08-29 Thread Marko Asplund
On Thu, 24 Aug 2017 13:46:27 GMT Justin Bertram wrote: > I would do this: > > 1) Invoke org.apache.activemq.artemis.api.core.client.ClientSession#stop > 2) Invoke org.apache.activemq.artemis.api.core.client.ClientConsumer#close > ... I just changed the code to close the consumer after closing

Re: Artemis v2.2: ActiveMQIllegalStateException with core API

2017-08-24 Thread Marko Asplund
On Wed, 23 Aug 2017 20:05:35 GMT Justin Bertram wrote: > So I just looked at the code again and I totally missed the Thread.sleep() > in consumeMessage() which nullifies my previous theory. My actual consumer code closes the session when the process is shut down. But, I guess in some cases this c

Re: Artemis v2.2: ActiveMQIllegalStateException with core API

2017-08-24 Thread Marko Asplund
On Thu, 24 Aug 2017 00:54:04 GMT Clebert Suconic wrote: > A session is supposed to be the contract of a thread. Aren't you using the > same season between producer and consumer and calling commit on both ends ? The producer and consumers create separate sessions and they aren't shared. In my act

Artemis v2.2: ActiveMQIllegalStateException with core API

2017-08-22 Thread Marko Asplund
ted in a sample here: https://gist.github.com/marko-asplund/983300e4bec59f53a13bc0d319a506f6 marko

Re: Artemis automatic client reconnection?

2016-10-21 Thread Marko Asplund
Seems to be working great - thanks! Marko Justin Bertram wrote: > I believe you should just need to specify a non-zero value for reconnectAttempts, e.g.: > > ActiveMQClient.createServerLocator("tcp://myhost:61616?reconnectAttempts=10"); > > Or you can invoke setReconnectAttempts() on the Server

Artemis automatic client reconnection?

2016-10-21 Thread Marko Asplund
Hi, How do I get an Artemis client session to automatically reconnect after a transient network disconnect or a server restart? Messages are consumed using the Artemis Core API message handler, so consumer processes are long-running and only create an Artemis client session at startup. Currently,

Artemis Core client-side threading

2016-09-27 Thread Marko Asplund
How does the Artemis client-side threading model work, especially with regard to thread safety? Can ClientSession and ClientProducer instances be safely shared across threads? It seems like MessageHandler thread pool size can be configured via ServerLocator. I've been reading the "Thread managemen

Re: Recommendations for Message broker, protocol and client library

2016-05-08 Thread Marko Asplund
On Thu, 5 May 2016 16:45:49 Justin Bertram wrote: One quick note...You are certainly free to use Apollo, but it is not under > active development at the moment as far as I'm aware. However, the Artemis > broker is an option for you as well as ActiveMQ 5.x. > Whichever broker you choose I would re

Recommendations for Message broker, protocol and client library

2016-05-05 Thread Marko Asplund
Hi, I need to implement a reliable work queue where multiple (~5) producers will submit tasks for consumers (~10) and I'm seeking practical advice on, which messaging broker, protocol and client libraries to use. Producers and consumers will likely reside in different data centers, so connections

Re: AMQP authentication trouble

2013-10-09 Thread Marko Asplund
I just tried connecting to ActiveMQ using SwiftMQ client 9.4.0 and that client library is able to authenticate and communicate with the server successfully. So, this seems to be a client-side issue either with the Qpid AMQP Messenger API usage or the API implementation. Are there any free alternat

AMQP authentication trouble

2013-10-09 Thread Marko Asplund
Hi, I'm trying to get my AMQP client (Qpid Messenger 0.5 based) to authenticate to an ActiveMQ 5.8.0 server, but for some reason the server fails to get the authentication info. Authentication credentials are passed in the address string like this: amqp://admin:password@127.0.0.1:5672/topic://tes

Re: Messaging protocol selection

2013-10-08 Thread Marko Asplund
Christian Posta wrote: > > Using the default protocol (Openwire) for Java. > Use STOMP for your PHP needs. > > Apollo has had some good community use. It's not a feature-complete drop-in > replacement for ActiveMQ 5.x yet, but should be suitable for the needs you > describe above. > > Apollo also s

Messaging protocol selection

2013-10-07 Thread Marko Asplund
Hi, I'm planning on deploying ActiveMQ for delivering event notifications across different applications and web sites. The events will be delivered to multiple recipients using publish-subscribe pattern. The number of clients is expected to be about 10-20 and they will be connecting over the Inter