You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@activemq.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2017/10/04 14:31:00 UTC

[jira] [Commented] (ARTEMIS-1448) Core to JMS message fails to convert priority

    [ https://issues.apache.org/jira/browse/ARTEMIS-1448?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16191330#comment-16191330 ] 

ASF GitHub Bot commented on ARTEMIS-1448:
-----------------------------------------

GitHub user jmesnil opened a pull request:

    https://github.com/apache/activemq-artemis/pull/1571

    [ARTEMIS-1448] Fix Core to JMS conversion

    priority is stored as a byte in the ICoreMessage's map.
    It is stored then in a int when it is converted to JMS (as JMSPriority
    header is an Integer).
    
    JIRA: https://issues.apache.org/jira/browse/ARTEMIS-1448

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/jmesnil/activemq-artemis ARTEMIS-1448_core_jms_conversion

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/activemq-artemis/pull/1571.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #1571
    
----
commit 8c7eb63b7abcf38e1b75046184119bc17b063d32
Author: Jeff Mesnil <jm...@gmail.com>
Date:   2017-10-04T14:28:43Z

    [ARTEMIS-1448] Fix Core to JMS conversion
    
    priority is stored as a byte in the ICoreMessage's map.
    It is stored then in a int when it is converted to JMS (as JMSPriority
    header is an Integer).
    
    JIRA: https://issues.apache.org/jira/browse/ARTEMIS-1448

----


> Core to JMS message fails to convert priority
> ---------------------------------------------
>
>                 Key: ARTEMIS-1448
>                 URL: https://issues.apache.org/jira/browse/ARTEMIS-1448
>             Project: ActiveMQ Artemis
>          Issue Type: Bug
>          Components: AMQP
>    Affects Versions: 2.3.0
>            Reporter: Jeff Mesnil
>
> Create a core client message with a priority of 9.
> Calls ICoreMessage.toMap() and then org.apache.activemq.artemis.jms.client.ActiveMQMessage#coreMaptoJMSMap() results in a ClassCastException:
> {code}
> java.lang.ClassCastException: java.lang.Integer cannot be cast to java.lang.Byte
> 	at org.apache.activemq.artemis.jms.client.ActiveMQMessage.coreMaptoJMSMap(ActiveMQMessage.java:72)
> 	at org.apache.activemq.artemis.jms.client.ConversionTest.testCoreToJMSConversion(ConversionTest.java:48)
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)