getBody() does not throw exceptions any more, changed to 2.0 approach

git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@758293 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Bosanac Dejan 2009-03-25 15:03:58 +00:00
parent 31c7e620c2
commit 65aef36600
1 changed files with 2 additions and 3 deletions

View File

@ -190,9 +190,8 @@ public class JournalEndpoint extends DefaultEndpoint {
incrementReference();
try {
ByteSequence body = null;
try {
body = exchange.getIn().getBody(ByteSequence.class);
} catch(NoTypeConversionAvailableException e) {
if (body == null) {
byte[] bytes = exchange.getIn().getBody(byte[].class);
if (bytes != null) {
body = new ByteSequence(bytes);