ARTEMIS-720 Add JMSX properties in AMQP<->JMS converter

This commit is contained in:
Martyn Taylor 2016-09-08 11:56:38 +01:00 committed by Clebert Suconic
parent a7cac9ba5c
commit db7dfba607
1 changed files with 15 additions and 4 deletions

View File

@ -18,6 +18,7 @@ package org.apache.activemq.artemis.core.protocol.proton.converter;
import javax.jms.BytesMessage;
import javax.jms.Destination;
import javax.jms.JMSException;
import javax.jms.MapMessage;
import javax.jms.Message;
import javax.jms.ObjectMessage;
@ -90,19 +91,29 @@ public class ActiveMQJMSVendor implements JMSVendor {
try {
message.setStringProperty("_AMQ_GROUP_ID", s);
}
catch (Exception e) {
e.printStackTrace();
catch (JMSException e) {
throw new RuntimeException(e);
}
}
@Override
public void setJMSXGroupSequence(Message message, int i) {
try {
message.setIntProperty("JMSXGroupSeq", i);
}
catch (JMSException e) {
throw new RuntimeException(e);
}
}
@Override
public void setJMSXDeliveryCount(Message message, long l) {
try {
message.setLongProperty("JMSXDeliveryCount", l);
}
catch (JMSException e) {
throw new RuntimeException(e);
}
}
public ServerJMSMessage wrapMessage(int messageType, ServerMessage wrapped, int deliveryCount) {