Re: can a client "refuse" a message?

2014-03-04 Thread Gary Tully
>>>>>>>> > >>>>>>>> hi all, > >>>>>>>>can a queue message consumer "refuse" a message after receive a > >>>>>> message? > >>>>>>>>because a client don't know the message in advance. > >>>>>>>>onMessage(Message msg){ > >>>>>>>> if(CannotProcess(msg)){ > >>>>>>>> //refuse this message > >>>>>>>> } > >>>>>>>> } > >>>>>>>> what I need is: if the message can't be processed by one client, > it > >>>>>>>> can be sent to another consumer. > >>>>>>>> if all consumer "refuse" this message, then this message will be > >>>>>>>> removed to dead letter queue or to the end of the queue. > >>>>>>>> > >>>>>>>> > >>>>>>>> If you reply to this email, your message will be added to the > >>>>>> discussion below: > >>>>>> > http://activemq.2283324.n4.nabble.com/can-a-client-refuse-a-message-tp4678441.html > >>>>>>>> To start a new topic under ActiveMQ - User, email > >>>>>> ml-node+s2283324n234180...@n4.nabble.com > >>>>>>>> To unsubscribe from ActiveMQ - User, click here. > >>>>>>>> NAML > >>>>>>> > >>>>>>> > >>>>>>> > >>>>>>> > >>>>>>> -- > >>>>>>> View this message in context: > >>>>>> > http://activemq.2283324.n4.nabble.com/can-a-client-refuse-a-message-tp4678441p4678446.html > >>>>>>> Sent from the ActiveMQ - User mailing list archive at Nabble.com. > >>>>>> > > > > > > > > -- > > http://redhat.com > > http://blog.garytully.com >

Re: can a client "refuse" a message?

2014-03-03 Thread Li Li
> >>>>>>> >>>>>>> Sent from my iPhone >>>>>>> >>>>>>>> On Mar 2, 2014, at 9:36 PM, "Li Li [via ActiveMQ]" < >>>>>> ml-node+s2283324n4678441...@n4.nabble.com> wrote: >>>&g

Re: can a client "refuse" a message?

2014-03-03 Thread Gary Tully
e >>>>>>> } >>>>>>> } >>>>>>> what I need is: if the message can't be processed by one client, it >>>>>>> can be sent to another consumer. >>>>>>> if all consumer "refuse" this message, then this message will be >>>>>>> removed to dead letter queue or to the end of the queue. >>>>>>> >>>>>>> >>>>>>> If you reply to this email, your message will be added to the >>>>> discussion below: >>>>> http://activemq.2283324.n4.nabble.com/can-a-client-refuse-a-message-tp4678441.html >>>>>>> To start a new topic under ActiveMQ - User, email >>>>> ml-node+s2283324n234180...@n4.nabble.com >>>>>>> To unsubscribe from ActiveMQ - User, click here. >>>>>>> NAML >>>>>> >>>>>> >>>>>> >>>>>> >>>>>> -- >>>>>> View this message in context: >>>>> http://activemq.2283324.n4.nabble.com/can-a-client-refuse-a-message-tp4678441p4678446.html >>>>>> Sent from the ActiveMQ - User mailing list archive at Nabble.com. >>>>> -- http://redhat.com http://blog.garytully.com

Re: can a client "refuse" a message?

2014-03-03 Thread Li Li
cause a client don't know the message in advance. >>>>>>onMessage(Message msg){ >>>>>> if(CannotProcess(msg)){ >>>>>> //refuse this message >>>>>> } >>>>>>

Re: can a client "refuse" a message?

2014-03-03 Thread Rob Davies
because a client don't know the message in advance. >>>>>onMessage(Message msg){ >>>>> if(CannotProcess(msg)){ >>>>> //refuse this message >>>>> } >>>>> } >>>>> what I

Re: can a client "refuse" a message?

2014-03-03 Thread Li Li
y one client, it >> >> can be sent to another consumer. >> >> if all consumer "refuse" this message, then this message will be >> >> removed to dead letter queue or to the end of the queue. >> >> >> >> >> >> If you reply t

Re: can a client "refuse" a message?

2014-03-03 Thread Noel OConnor
I need is: if the message can't be processed by one client, it > >> can be sent to another consumer. > >> if all consumer "refuse" this message, then this message will be > >> removed to dead letter queue or to the end of the queue. > >> > >

Re: can a client "refuse" a message?

2014-03-02 Thread Li Li
all consumer "refuse" this message, then this message will be >> removed to dead letter queue or to the end of the queue. >> >> >> If you reply to this email, your message will be added to the discussion >> below: >> http://activemq.2283324.n4.nabble.

Re: can a client "refuse" a message?

2014-03-02 Thread artnaseef
umer "refuse" this message, then this message will be > removed to dead letter queue or to the end of the queue. > > > If you reply to this email, your message will be added to the discussion > below: > http://activemq.2283324.n4.nabble.com/can-a-client-refuse-a-m

Re: can a client "refuse" a message?

2014-03-02 Thread Li Li
I have tested it with auto_acknowledge mode. it will be redediveryed to the same consumer again and again before be moved to dead letter queue. what I want is, this message be sent to other consumers On Mon, Mar 3, 2014 at 1:13 PM, Noel OConnor wrote: > If the mdb is in a transaction you could tr

Re: can a client "refuse" a message?

2014-03-02 Thread Noel OConnor
If the mdb is in a transaction you could try rolling it back. If not (I think) the message should be redelivered if you throw a runtime exception from within the MDB. On Mon, Mar 3, 2014 at 3:35 PM, Li Li wrote: > hi all, > can a queue message consumer "refuse" a message after receive a > m

can a client "refuse" a message?

2014-03-02 Thread Li Li
hi all, can a queue message consumer "refuse" a message after receive a message? because a client don't know the message in advance. onMessage(Message msg){ if(CannotProcess(msg)){ //refuse this message } } what I need is: if the message can't be