Return-Path: X-Original-To: apmail-camel-users-archive@www.apache.org Delivered-To: apmail-camel-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 37EF57717 for ; Sun, 27 Nov 2011 16:59:09 +0000 (UTC) Received: (qmail 83090 invoked by uid 500); 27 Nov 2011 16:59:08 -0000 Delivered-To: apmail-camel-users-archive@camel.apache.org Received: (qmail 83054 invoked by uid 500); 27 Nov 2011 16:59:08 -0000 Mailing-List: contact users-help@camel.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@camel.apache.org Delivered-To: mailing list users@camel.apache.org Received: (qmail 83046 invoked by uid 99); 27 Nov 2011 16:59:08 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 27 Nov 2011 16:59:08 +0000 X-ASF-Spam-Status: No, hits=0.6 required=5.0 tests=FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS,URI_HEX X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of claus.ibsen@gmail.com designates 209.85.215.173 as permitted sender) Received: from [209.85.215.173] (HELO mail-ey0-f173.google.com) (209.85.215.173) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 27 Nov 2011 16:59:04 +0000 Received: by eaai10 with SMTP id i10so1580409eaa.32 for ; Sun, 27 Nov 2011 08:58:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type:content-transfer-encoding; bh=mxPkXn1HlnbUw1R+Bm9TCJET4x+xvX4nFBMQotzVp8A=; b=UyOyYqv7D6hoED6cjbBTJ9mSx2Xsqj+oe9oOK9VRhEpb+khz/RaCxAroJMGy5tDFcY kM2C/iL/yoL3BlNPvBSXV8FcIHyJ96N2YI0SMVDQku1o7F3wkdAPVr/d9buMHrvqvufa iuFIJ0qhGan3DD4PAeL3mI+/BV5oBZl6Nejkw= Received: by 10.14.13.7 with SMTP id a7mr774723eea.51.1322413123143; Sun, 27 Nov 2011 08:58:43 -0800 (PST) MIME-Version: 1.0 Received: by 10.14.99.5 with HTTP; Sun, 27 Nov 2011 08:58:22 -0800 (PST) In-Reply-To: References: <1316606677978-4826097.post@n5.nabble.com> From: Claus Ibsen Date: Sun, 27 Nov 2011 17:58:22 +0100 Message-ID: Subject: Re: Global exception not invoked in case of Exception fired while iterating through File Splitter To: users@camel.apache.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable You need to handle the exception in the onException. On Sun, Nov 27, 2011 at 3:28 PM, nilsoni wrote: > Hi Clause, > It seems that this issue is not yet resolved. Can you please try the code > uploaded by me in the nabble > http://camel.465427.n5.nabble.com/Global-exception-not-invoked-in-case-of= -Exception-fired-while-iterating-through-File-Splitter-td4826097.htmlTry > the file SplitInProgress.java > > > The exception is still uncaught by the clause > onException(Throwable.class) > .process(customMoveFailed()); > > On Sat, Sep 24, 2011 at 1:20 PM, Claus Ibsen-2 [via Camel] < > ml-node+s465427n4836157h47@n5.nabble.com> wrote: > >> Hi >> >> I have created a ticket >> https://issues.apache.org/jira/browse/CAMEL-4482 >> >> On Fri, Sep 23, 2011 at 6:14 PM, Claus Ibsen <[hidden email]> >> wrote: >> >> > Hi >> > >> > I had a bit time right now and will look into it. I have reproduce the >> > issue and have a pending fix. >> > Fell free to create a JIRA ticket, a I am about to rush out the door >> > for the weekend. >> > >> > >> > On Wed, Sep 21, 2011 at 2:04 PM, nilsoni <[hidden email]> >> wrote: >> >> Hi All, >> >> I have written a file route which picks up xml files from a specified >> >> location. This file is passed to a splitter (actually an Expression >> written >> >> by me) which returns a custom made Iterator and returns to Camel. Whe= n >> camel >> >> is iterating through my iterator, if I throw RuntimeException, it is >> not >> >> getting caught in global exception and hence i am not able to log the >> error. >> >> >> >> In actual, my entire code is a test class attached with this mail. >> Anyone >> >> can run it directly. There is one strange behavior also noticed by me= . >> If i >> >> throw RuntimeException from the Expression written by me, it is >> properly >> >> caught by the global exception. You can find both the occurance of >> >> RuntimeException in the code (the commented one is working properly). >> >> >> >> Any help will be appreciated. >> >> >> >> >> http://camel.465427.n5.nabble.com/file/n4826097/SplitInProgressTest.java >> >> SplitInProgressTest.java >> >> >> >> >> >> Regards, >> >> Nilesh Soni >> >> http://camel.465427.n5.nabble.com/file/n4826097/SampleEventFile.event >> >> SampleEventFile.event >> >> >> >> -- >> >> View this message in context: >> http://camel.465427.n5.nabble.com/Global-exception-not-invoked-in-case-o= f-Exception-fired-while-iterating-through-File-Splitter-tp4826097p4826097.h= tml >> >> Sent from the Camel - Users mailing list archive at Nabble.com. >> > >> > >> > >> > -- >> > Claus Ibsen >> > ----------------- >> > FuseSource >> > Email: [hidden email] >> > Web: http://fusesource.com >> > Twitter: davsclaus, fusenews >> > Blog: http://davsclaus.blogspot.com/ >> > Author of Camel in Action: http://www.manning.com/ibsen/ >> > >> >> >> >> -- >> Claus Ibsen >> ----------------- >> FuseSource >> Email: [hidden email] >> Web: http://fusesource.com >> Twitter: davsclaus, fusenews >> Blog: http://davsclaus.blogspot.com/ >> Author of Camel in Action: http://www.manning.com/ibsen/ >> >> >> ------------------------------ >> =A0If you reply to this email, your message will be added to the discuss= ion >> below: >> >> http://camel.465427.n5.nabble.com/Global-exception-not-invoked-in-case-o= f-Exception-fired-while-iterating-through-File-Splitter-tp4826097p4836157.h= tml >> =A0To unsubscribe from Global exception not invoked in case of Exception >> fired while iterating through File Splitter, click here. >> >> > > > > -- > Regards, > Nilesh Soni > > > -- > View this message in context: http://camel.465427.n5.nabble.com/Global-ex= ception-not-invoked-in-case-of-Exception-fired-while-iterating-through-File= -Splitter-tp4826097p5026545.html > Sent from the Camel - Users mailing list archive at Nabble.com. --=20 Claus Ibsen ----------------- FuseSource Email: cibsen@fusesource.com Web: http://fusesource.com Twitter: davsclaus, fusenews Blog: http://davsclaus.blogspot.com/ Author of Camel in Action: http://www.manning.com/ibsen/