Return-Path: Delivered-To: apmail-activemq-users-archive@www.apache.org Received: (qmail 66765 invoked from network); 29 Sep 2008 16:13:18 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 29 Sep 2008 16:13:18 -0000 Received: (qmail 30178 invoked by uid 500); 29 Sep 2008 16:13:15 -0000 Delivered-To: apmail-activemq-users-archive@activemq.apache.org Received: (qmail 30164 invoked by uid 500); 29 Sep 2008 16:13:15 -0000 Mailing-List: contact users-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@activemq.apache.org Delivered-To: mailing list users@activemq.apache.org Received: (qmail 30153 invoked by uid 99); 29 Sep 2008 16:13:15 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 29 Sep 2008 09:13:15 -0700 X-ASF-Spam-Status: No, hits=3.2 required=10.0 tests=HTML_MESSAGE,SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (athena.apache.org: local policy) Received: from [66.249.82.230] (HELO wx-out-0506.google.com) (66.249.82.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 29 Sep 2008 16:12:12 +0000 Received: by wx-out-0506.google.com with SMTP id s12so438537wxc.26 for ; Mon, 29 Sep 2008 09:12:28 -0700 (PDT) Received: by 10.142.133.8 with SMTP id g8mr2275711wfd.253.1222704748176; Mon, 29 Sep 2008 09:12:28 -0700 (PDT) Received: by 10.143.14.8 with HTTP; Mon, 29 Sep 2008 09:12:27 -0700 (PDT) Message-ID: <56b1dfc30809290912u1075892uffc7c97d2e996e2e@mail.gmail.com> Date: Mon, 29 Sep 2008 09:12:27 -0700 From: "Mick Knutson" To: Camel , "Active MQ" Subject: Re: issue routing Exchange to custom method in Processor In-Reply-To: <56b1dfc30809261510w5519fe4bwe78f76786691a038@mail.gmail.com> MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_33711_3882756.1222704748168" References: <56b1dfc30809261222m7cd445a7pf13139b13b791234@mail.gmail.com> <56b1dfc30809261510w5519fe4bwe78f76786691a038@mail.gmail.com> X-Virus-Checked: Checked by ClamAV on apache.org ------=_Part_33711_3882756.1222704748168 Content-Type: text/plain; charset=WINDOWS-1252 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Can someone help me? On Fri, Sep 26, 2008 at 3:10 PM, Mick Knutson wrote= : > The funny thing is, when I have an error with the message coming from thi= s > queue, which I do because process(Exchange) does not expect my message bo= dy, > the message gets routed to the proper deadLetter channel. > > > > > On Fri, Sep 26, 2008 at 12:22 PM, Mick Knutson wr= ote: > >> I have a Processor with 2 different methods: >> >> The standard: >> *public void process(Exchange exchange) { >> * >> >> and a custom: >> >> *@MessageDriven(uri =3D Constants.CHANNEL_GG_CS_COMMAND_STATUS) >> public void onMessage(Exchange exchange) * >> >> Now here is my route: >> >> * from(Constants.CHANNEL_GG_CS_CR_ADD) >> .errorHandler( >> >> deadLetterChannel(Constants.CHANNEL_GG_CS_CR_ADD_ERROR) >> //.maximumRedeliveries(2) >> //.initialRedeliveryDelay(1) >> .loggingLevel(LoggingLevel.DEBUG) >> ).processRef("changeRequestController") >> .to(Constants.CHANNEL_GG_CS_COMMAND_CLUSTER); >> >> >> // Route for command status updates. >> from(Constants.CHANNEL_GG_CS_COMMAND_STATUS) >> .errorHandler( >> >> deadLetterChannel(Constants.CHANNEL_GG_CS_COMMAND_STATUS_ERROR).maximumR= edeliveries(2) >> .initialRedeliveryDelay(1) >> .loggingLevel(LoggingLevel.INFO) >> ).to("bean:changeRequestController?methodName=3DonMessag= e"); >> * >> >> So when I get a message on *Constants.CHANNEL_GG_CS_CR_ADD my >> process(Exchange) method is called, and that rout is fine. >> >> However, I get a response message back on **Constants.CHANNEL_GG_CS_COMM= AND_STATUS >> but it is also processed by *the *process(Exchange) instead of my >> onMessage**(Exchange)* >> >> I have tried @MessageDriven annotation as well as the route builder but >> neither works. >> >> Am I forced to have each process in a single class? >> >> >> >> -- >> --- >> Thank You=85 >> >> Mick Knutson >> BASE Logic, inc. >> (415) 354-4215 >> >> Website: http://baselogic.com >> Blog: http://baselogic.com/blog >> BLiNC Magazine: http://blincmagazine.com >> Linked IN: http://linkedin.com/in/mickknutson >> DJ Mick: http://djmick.com >> MySpace: http://myspace.com/mickknutson >> Vacation Rental: http://tahoe.baselogic.com >> >> > > > -- > --- > Thank You=85 > > Mick Knutson > BASE Logic, inc. > (415) 354-4215 > > Website: http://baselogic.com > Blog: http://baselogic.com/blog > BLiNC Magazine: http://blincmagazine.com > Linked IN: http://linkedin.com/in/mickknutson > DJ Mick: http://djmick.com > MySpace: http://myspace.com/mickknutson > Vacation Rental: http://tahoe.baselogic.com > > --=20 --- Thank You=85 Mick Knutson BASE Logic, inc. (415) 354-4215 Website: http://baselogic.com Blog: http://baselogic.com/blog BLiNC Magazine: http://blincmagazine.com Linked IN: http://linkedin.com/in/mickknutson DJ Mick: http://djmick.com MySpace: http://myspace.com/mickknutson Vacation Rental: http://tahoe.baselogic.com ------=_Part_33711_3882756.1222704748168--