diff options
author | Robert Gemmell <robbie@apache.org> | 2015-03-04 18:54:47 +0000 |
---|---|---|
committer | Robert Gemmell <robbie@apache.org> | 2015-03-04 18:54:47 +0000 |
commit | 37fe66d68304d1b112f0bb012665e12140250bed (patch) | |
tree | d5abe2be5c85adb21785dd36858577bbb7b2f3b9 | |
parent | 598a9d7302ffad7653cada366084c3516ee35ad8 (diff) | |
download | qpid-python-37fe66d68304d1b112f0bb012665e12140250bed.tar.gz |
QPID-6432: when looking for the JMSType value use the message Subject first if present
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1664114 13f79535-47bb-0310-9956-ffa450edef68
-rwxr-xr-x | qpid/java/broker-plugins/amqp-1-0-protocol/src/main/java/org/apache/qpid/server/protocol/v1_0/MessageMetaData_1_0.java | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/qpid/java/broker-plugins/amqp-1-0-protocol/src/main/java/org/apache/qpid/server/protocol/v1_0/MessageMetaData_1_0.java b/qpid/java/broker-plugins/amqp-1-0-protocol/src/main/java/org/apache/qpid/server/protocol/v1_0/MessageMetaData_1_0.java index fbc24ba454..6800b14d65 100755 --- a/qpid/java/broker-plugins/amqp-1-0-protocol/src/main/java/org/apache/qpid/server/protocol/v1_0/MessageMetaData_1_0.java +++ b/qpid/java/broker-plugins/amqp-1-0-protocol/src/main/java/org/apache/qpid/server/protocol/v1_0/MessageMetaData_1_0.java @@ -493,7 +493,13 @@ public class MessageMetaData_1_0 implements StorableMessageMetaData public String getType() { + String subject = getSubject(); + if(subject != null) + { + return subject; + } + // Use legacy annotation if present and there was no subject if(_messageAnnotations == null || _messageAnnotations.get(JMS_TYPE) == null) { return null; |