Return-Path: X-Original-To: apmail-qpid-commits-archive@www.apache.org Delivered-To: apmail-qpid-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id EB99D17BA1 for ; Fri, 3 Oct 2014 12:45:20 +0000 (UTC) Received: (qmail 83665 invoked by uid 500); 3 Oct 2014 12:45:20 -0000 Delivered-To: apmail-qpid-commits-archive@qpid.apache.org Received: (qmail 83630 invoked by uid 500); 3 Oct 2014 12:45:20 -0000 Mailing-List: contact commits-help@qpid.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@qpid.apache.org Delivered-To: mailing list commits@qpid.apache.org Received: (qmail 83577 invoked by uid 99); 3 Oct 2014 12:45:20 -0000 Received: from tyr.zones.apache.org (HELO tyr.zones.apache.org) (140.211.11.114) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 03 Oct 2014 12:45:20 +0000 Received: by tyr.zones.apache.org (Postfix, from userid 65534) id 6F273A1F164; Fri, 3 Oct 2014 12:45:20 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: robbie@apache.org To: commits@qpid.apache.org Date: Fri, 03 Oct 2014 12:45:25 -0000 Message-Id: In-Reply-To: <03c10d284acc4524b5256835e8559bd7@git.apache.org> References: <03c10d284acc4524b5256835e8559bd7@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: [6/8] git commit: add content type checking to initialise the correct delegate, enable test add content type checking to initialise the correct delegate, enable test Project: http://git-wip-us.apache.org/repos/asf/qpid-jms/repo Commit: http://git-wip-us.apache.org/repos/asf/qpid-jms/commit/0001dd5f Tree: http://git-wip-us.apache.org/repos/asf/qpid-jms/tree/0001dd5f Diff: http://git-wip-us.apache.org/repos/asf/qpid-jms/diff/0001dd5f Branch: refs/heads/master Commit: 0001dd5f40a2cd23a3318623ad56dfa455ae3048 Parents: 19d2d05 Author: Robert Gemmell Authored: Fri Oct 3 11:31:54 2014 +0100 Committer: Robert Gemmell Committed: Fri Oct 3 11:31:54 2014 +0100 ---------------------------------------------------------------------- .../jms/provider/amqp/message/AmqpJmsObjectMessageFacade.java | 4 ++-- .../qpid/jms/integration/ObjectMessageIntegrationTest.java | 1 - 2 files changed, 2 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/qpid-jms/blob/0001dd5f/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/message/AmqpJmsObjectMessageFacade.java ---------------------------------------------------------------------- diff --git a/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/message/AmqpJmsObjectMessageFacade.java b/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/message/AmqpJmsObjectMessageFacade.java index 20053d6..2fc08fe 100644 --- a/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/message/AmqpJmsObjectMessageFacade.java +++ b/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/message/AmqpJmsObjectMessageFacade.java @@ -64,8 +64,8 @@ public class AmqpJmsObjectMessageFacade extends AmqpJmsMessageFacade implements public AmqpJmsObjectMessageFacade(AmqpConsumer consumer, Message message) { super(consumer, message); - // TODO detect the content type and init the proper delegate. - initDelegate(false); + boolean javaSerialized = AmqpMessageSupport.SERIALIZED_JAVA_OBJECT_CONTENT_TYPE.equals(message.getContentType()); + initDelegate(!javaSerialized); } /** http://git-wip-us.apache.org/repos/asf/qpid-jms/blob/0001dd5f/qpid-jms-client/src/test/java/org/apache/qpid/jms/integration/ObjectMessageIntegrationTest.java ---------------------------------------------------------------------- diff --git a/qpid-jms-client/src/test/java/org/apache/qpid/jms/integration/ObjectMessageIntegrationTest.java b/qpid-jms-client/src/test/java/org/apache/qpid/jms/integration/ObjectMessageIntegrationTest.java index e08678e..f965f63 100644 --- a/qpid-jms-client/src/test/java/org/apache/qpid/jms/integration/ObjectMessageIntegrationTest.java +++ b/qpid-jms-client/src/test/java/org/apache/qpid/jms/integration/ObjectMessageIntegrationTest.java @@ -256,7 +256,6 @@ public class ObjectMessageIntegrationTest extends QpidJmsTestCase } @Test(timeout = 5000) - @Ignore //TODO: currently failing due to being unable to receive the AmqpValue body section type public void testRecieveBasicObjectMessageWithAmqpTypedContentAndJMSMessageTypeAnnotation() throws Exception { try(TestAmqpPeer testPeer = new TestAmqpPeer(IntegrationTestFixture.PORT);) --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscribe@qpid.apache.org For additional commands, e-mail: commits-help@qpid.apache.org