activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dej...@apache.org
Subject svn commit: r758293 - /activemq/trunk/activemq-camel/src/main/java/org/apache/activemq/camel/component/JournalEndpoint.java
Date Wed, 25 Mar 2009 15:04:02 GMT
Author: dejanb
Date: Wed Mar 25 15:03:58 2009
New Revision: 758293

URL: http://svn.apache.org/viewvc?rev=758293&view=rev
Log:
getBody() does not throw exceptions any more, changed to 2.0 approach

Modified:
    activemq/trunk/activemq-camel/src/main/java/org/apache/activemq/camel/component/JournalEndpoint.java

Modified: activemq/trunk/activemq-camel/src/main/java/org/apache/activemq/camel/component/JournalEndpoint.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-camel/src/main/java/org/apache/activemq/camel/component/JournalEndpoint.java?rev=758293&r1=758292&r2=758293&view=diff
==============================================================================
--- activemq/trunk/activemq-camel/src/main/java/org/apache/activemq/camel/component/JournalEndpoint.java
(original)
+++ activemq/trunk/activemq-camel/src/main/java/org/apache/activemq/camel/component/JournalEndpoint.java
Wed Mar 25 15:03:58 2009
@@ -190,9 +190,8 @@
                 incrementReference();
                 try {
                     ByteSequence body = null;
-                    try {
-                        body = exchange.getIn().getBody(ByteSequence.class);
-                    } catch(NoTypeConversionAvailableException e) {
+                    body = exchange.getIn().getBody(ByteSequence.class);
+                    if (body == null) {
                         byte[] bytes = exchange.getIn().getBody(byte[].class);
                         if (bytes != null) {
                             body = new ByteSequence(bytes);



Mime
View raw message