You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by da...@apache.org on 2012/04/18 13:44:35 UTC

svn commit: r1327455 - in /camel/branches/camel-2.9.x: ./ camel-core/src/test/java/org/apache/camel/component/file/FileConsumerCustomExceptionHandlerTest.java

Author: davsclaus
Date: Wed Apr 18 11:44:34 2012
New Revision: 1327455

URL: http://svn.apache.org/viewvc?rev=1327455&view=rev
Log:
CAMEL-5178: File consumer should use exception handler to handle all component specific exceptions. Add example how to plugin a custom exception handler and send that to a Camel route so Camel routing onException can deal with the exception. Reduce the out of the box logging exception handler to WARN level.

Modified:
    camel/branches/camel-2.9.x/   (props changed)
    camel/branches/camel-2.9.x/camel-core/src/test/java/org/apache/camel/component/file/FileConsumerCustomExceptionHandlerTest.java

Propchange: camel/branches/camel-2.9.x/
------------------------------------------------------------------------------
  Merged /camel/trunk:r1327449

Propchange: camel/branches/camel-2.9.x/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.

Modified: camel/branches/camel-2.9.x/camel-core/src/test/java/org/apache/camel/component/file/FileConsumerCustomExceptionHandlerTest.java
URL: http://svn.apache.org/viewvc/camel/branches/camel-2.9.x/camel-core/src/test/java/org/apache/camel/component/file/FileConsumerCustomExceptionHandlerTest.java?rev=1327455&r1=1327454&r2=1327455&view=diff
==============================================================================
--- camel/branches/camel-2.9.x/camel-core/src/test/java/org/apache/camel/component/file/FileConsumerCustomExceptionHandlerTest.java (original)
+++ camel/branches/camel-2.9.x/camel-core/src/test/java/org/apache/camel/component/file/FileConsumerCustomExceptionHandlerTest.java Wed Apr 18 11:44:34 2012
@@ -56,6 +56,7 @@ public class FileConsumerCustomException
         return jndi;
     }
 
+    // START SNIPPET: e2
     @Override
     protected RouteBuilder createRouteBuilder() throws Exception {
         return new RouteBuilder() {
@@ -84,6 +85,7 @@ public class FileConsumerCustomException
             }
         };
     }
+    // END SNIPPET: e1
 
     // START SNIPPET: e1
     /**
@@ -127,7 +129,6 @@ public class FileConsumerCustomException
     }
     // END SNIPPET: e1
 
-
     // used for simulating exception during acquiring a lock on the file
     private class MyReadLockStrategy implements GenericFileExclusiveReadLockStrategy {