Return-Path: X-Original-To: apmail-camel-issues-archive@minotaur.apache.org Delivered-To: apmail-camel-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 76EA21008E for ; Fri, 21 Mar 2014 16:29:52 +0000 (UTC) Received: (qmail 23688 invoked by uid 500); 21 Mar 2014 16:29:47 -0000 Delivered-To: apmail-camel-issues-archive@camel.apache.org Received: (qmail 23526 invoked by uid 500); 21 Mar 2014 16:29:46 -0000 Mailing-List: contact issues-help@camel.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@camel.apache.org Delivered-To: mailing list issues@camel.apache.org Received: (qmail 23173 invoked by uid 99); 21 Mar 2014 16:29:44 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 21 Mar 2014 16:29:44 +0000 Date: Fri, 21 Mar 2014 16:29:44 +0000 (UTC) From: "Scott England-Sullivan (JIRA)" To: issues@camel.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (CAMEL-6820) Improve SJMS handling of exchange body data types MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/CAMEL-6820?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13943206#comment-13943206 ] Scott England-Sullivan commented on CAMEL-6820: ----------------------------------------------- Thanks Willem. I was about to push it out myself. ses Scott England-Sullivan blog:sully6768.blogspot.com twitter:@sully6768 > Improve SJMS handling of exchange body data types > ------------------------------------------------- > > Key: CAMEL-6820 > URL: https://issues.apache.org/jira/browse/CAMEL-6820 > Project: Camel > Issue Type: Improvement > Components: camel-sjms > Affects Versions: 2.12.1 > Reporter: Nigel Longton > Assignee: Scott England-Sullivan > Fix For: 2.12.4, 2.13.1 > > > With a route as below > from("file:fname.txt").to("sjms:queue:qname") > we get an error because the Jms message type is of type Message. > The issue seems to be in JmsMessageHelper.discoverMessageTypeFromPayload. > GenericFile is the payload object which is not serializable itself. sjms has this line: > else if (Serializable.class.isInstance(payload)) { > answer = JmsMessageType.Object; > JMS component has this code in the JmsBinding class > case Object: > ObjectMessage message = session.createObjectMessage(); > if (body != null) { > try { > Serializable payload = context.getTypeConverter().mandatoryConvertTo(Serializable.class, exchange, body); > message.setObject(payload); -- This message was sent by Atlassian JIRA (v6.2#6252)