You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by Websphere and ActiveMQ <de...@hotmail.com> on 2009/05/26 23:34:43 UTC
Now another problem appears
Right now I can receive message from ActiveMQ on linux by Java Client, but I
have to run java client many many times, then I can receive the message.
However, J2EE MDB hasn't this problem, every times I use Java client to send
message, it can receive message on time.
I use default setting for ActiveMQ.
--
View this message in context: http://www.nabble.com/Now-another-problem-appears-tp23731817p23731817.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.
Re: Now another problem appears
Posted by Websphere and ActiveMQ <de...@hotmail.com>.
I tried to use receive(500) to receive message, it looks work correctly. if I
use receiveNoWait, sometime works, sometimes not.
What I want to know is that there is a way to configure ActiveMQ to resolve
this problem? thanks
Gary Tully wrote:
>
> If you are using consumer.receive(), add a small timeout to give the
> broker
> a chance to see your subscription, like receive(500). The MDB probably
> uses
> a message listener, you could use that approach in your java client also.
>
>
> 2009/5/26 Websphere and ActiveMQ <de...@hotmail.com>
>
>>
>> Right now I can receive message from ActiveMQ on linux by Java Client,
>> but
>> I
>> have to run java client many many times, then I can receive the message.
>> However, J2EE MDB hasn't this problem, every times I use Java client to
>> send
>> message, it can receive message on time.
>>
>> I use default setting for ActiveMQ.
>> --
>> View this message in context:
>> http://www.nabble.com/Now-another-problem-appears-tp23731817p23731817.html
>> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>>
>>
>
>
> --
> http://blog.garytully.com
>
> Open Source SOA
> http://FUSESource.com
>
>
--
View this message in context: http://www.nabble.com/Now-another-problem-appears-tp23731817p23742962.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.
Re: Now another problem appears
Posted by Websphere and ActiveMQ <de...@hotmail.com>.
Thanks,
Well, I used queueReceiver.receiveNoWait() method to receive message, but
this method had not this issue when I used IBM MQ as MQM. I cannot use
message listener here because it's client trigger the receiving message
behaviour.
Gary Tully wrote:
>
> If you are using consumer.receive(), add a small timeout to give the
> broker
> a chance to see your subscription, like receive(500). The MDB probably
> uses
> a message listener, you could use that approach in your java client also.
>
>
> 2009/5/26 Websphere and ActiveMQ <de...@hotmail.com>
>
>>
>> Right now I can receive message from ActiveMQ on linux by Java Client,
>> but
>> I
>> have to run java client many many times, then I can receive the message.
>> However, J2EE MDB hasn't this problem, every times I use Java client to
>> send
>> message, it can receive message on time.
>>
>> I use default setting for ActiveMQ.
>> --
>> View this message in context:
>> http://www.nabble.com/Now-another-problem-appears-tp23731817p23731817.html
>> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>>
>>
>
>
> --
> http://blog.garytully.com
>
> Open Source SOA
> http://FUSESource.com
>
>
--
View this message in context: http://www.nabble.com/Now-another-problem-appears-tp23731817p23741962.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.
Re: Now another problem appears
Posted by Gary Tully <ga...@gmail.com>.
If you are using consumer.receive(), add a small timeout to give the broker
a chance to see your subscription, like receive(500). The MDB probably uses
a message listener, you could use that approach in your java client also.
2009/5/26 Websphere and ActiveMQ <de...@hotmail.com>
>
> Right now I can receive message from ActiveMQ on linux by Java Client, but
> I
> have to run java client many many times, then I can receive the message.
> However, J2EE MDB hasn't this problem, every times I use Java client to
> send
> message, it can receive message on time.
>
> I use default setting for ActiveMQ.
> --
> View this message in context:
> http://www.nabble.com/Now-another-problem-appears-tp23731817p23731817.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>
>
--
http://blog.garytully.com
Open Source SOA
http://FUSESource.com