You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@qpid.apache.org by ro...@apache.org on 2014/12/16 18:34:18 UTC
qpid-jms git commit: remove support for sending string values for the
old destination type annotations
Repository: qpid-jms
Updated Branches:
refs/heads/master 71422525c -> 0d5adeb03
remove support for sending string values for the old destination type annotations
Project: http://git-wip-us.apache.org/repos/asf/qpid-jms/repo
Commit: http://git-wip-us.apache.org/repos/asf/qpid-jms/commit/0d5adeb0
Tree: http://git-wip-us.apache.org/repos/asf/qpid-jms/tree/0d5adeb0
Diff: http://git-wip-us.apache.org/repos/asf/qpid-jms/diff/0d5adeb0
Branch: refs/heads/master
Commit: 0d5adeb038ea9be500c91bc348a8c169779a522d
Parents: 7142252
Author: Robert Gemmell <ro...@apache.org>
Authored: Tue Dec 16 17:31:48 2014 +0000
Committer: Robert Gemmell <ro...@apache.org>
Committed: Tue Dec 16 17:31:48 2014 +0000
----------------------------------------------------------------------
.../qpid/jms/provider/amqp/AmqpConnection.java | 8 --
.../qpid/jms/provider/amqp/AmqpProvider.java | 9 ---
.../amqp/message/AmqpDestinationHelper.java | 48 ++++-------
.../amqp/message/AmqpJmsMessageFacade.java | 4 +-
.../jms/integration/MessageIntegrationTest.java | 84 --------------------
.../amqp/message/AmqpDestinationHelperTest.java | 54 +++++++------
6 files changed, 47 insertions(+), 160 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/qpid-jms/blob/0d5adeb0/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/AmqpConnection.java
----------------------------------------------------------------------
diff --git a/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/AmqpConnection.java b/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/AmqpConnection.java
index 7ee95be..859a404 100644
--- a/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/AmqpConnection.java
+++ b/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/AmqpConnection.java
@@ -288,14 +288,6 @@ public class AmqpConnection extends AmqpAbstractResource<JmsConnectionInfo, Conn
}
/**
- * @return true if the provider has been configured to use byte values for
- * destination type annotations.
- */
- public boolean isUseByteDestinationTypeAnnotation() {
- return provider.isUseByteDestinationTypeAnnotation();
- }
-
- /**
* @return true if anonymous producers should be cached or closed on send complete.
*/
public boolean isAnonymousProducerCache() {
http://git-wip-us.apache.org/repos/asf/qpid-jms/blob/0d5adeb0/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/AmqpProvider.java
----------------------------------------------------------------------
diff --git a/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/AmqpProvider.java b/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/AmqpProvider.java
index 1a34350..48d50ce 100644
--- a/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/AmqpProvider.java
+++ b/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/AmqpProvider.java
@@ -91,7 +91,6 @@ public class AmqpProvider extends AbstractProvider implements TransportListener
private boolean traceBytes;
private boolean presettleConsumers;
private boolean presettleProducers;
- private boolean useByteDestinationTypeAnnotation = true;
private long connectTimeout = JmsConnectionInfo.DEFAULT_CONNECT_TIMEOUT;
private long closeTimeout = JmsConnectionInfo.DEFAULT_CLOSE_TIMEOUT;
private long requestTimeout = JmsConnectionInfo.DEFAULT_REQUEST_TIMEOUT;
@@ -864,14 +863,6 @@ public class AmqpProvider extends AbstractProvider implements TransportListener
this.presettleProducers = presettle;
}
- public void setUseByteDestinationTypeAnnotation(boolean useByteDestinationTypeAnnotation) {
- this.useByteDestinationTypeAnnotation = useByteDestinationTypeAnnotation;
- }
-
- public boolean isUseByteDestinationTypeAnnotation() {
- return useByteDestinationTypeAnnotation;
- }
-
/**
* @return the currently set Max Frame Size value.
*/
http://git-wip-us.apache.org/repos/asf/qpid-jms/blob/0d5adeb0/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/message/AmqpDestinationHelper.java
----------------------------------------------------------------------
diff --git a/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/message/AmqpDestinationHelper.java b/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/message/AmqpDestinationHelper.java
index 0a4833a..1a31b97 100644
--- a/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/message/AmqpDestinationHelper.java
+++ b/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/message/AmqpDestinationHelper.java
@@ -115,9 +115,9 @@ public class AmqpDestinationHelper {
return new JmsQueue(address);
}
- public void setToAddressFromDestination(AmqpJmsMessageFacade message, JmsDestination destination, boolean useByteValue) {
+ public void setToAddressFromDestination(AmqpJmsMessageFacade message, JmsDestination destination) {
String address = destination != null ? destination.getName() : null;
- Object typeValue = toTypeAnnotation(destination, useByteValue);
+ Object typeValue = toTypeAnnotation(destination);
message.setToAddress(address);
@@ -128,9 +128,9 @@ public class AmqpDestinationHelper {
}
}
- public void setReplyToAddressFromDestination(AmqpJmsMessageFacade message, JmsDestination destination, boolean useByteValue) {
+ public void setReplyToAddressFromDestination(AmqpJmsMessageFacade message, JmsDestination destination) {
String replyToAddress = destination != null ? destination.getName() : null;
- Object typeValue = toTypeAnnotation(destination, useByteValue);
+ Object typeValue = toTypeAnnotation(destination);
message.setReplyToAddress(replyToAddress);
@@ -145,41 +145,25 @@ public class AmqpDestinationHelper {
* @return the annotation type value, or null if the supplied destination
* is null or can't be classified
*/
- private Object toTypeAnnotation(JmsDestination destination, boolean useByteValue) {
+ private Object toTypeAnnotation(JmsDestination destination) {
if (destination == null) {
return null;
}
- if(useByteValue)
- {
- if (destination.isQueue()) {
- if (destination.isTemporary()) {
- return TEMP_QUEUE_TYPE;
- } else {
- return QUEUE_TYPE;
- }
- } else if (destination.isTopic()) {
- if (destination.isTemporary()) {
- return TEMP_TOPIC_TYPE;
- } else {
- return TOPIC_TYPE;
- }
+ if (destination.isQueue()) {
+ if (destination.isTemporary()) {
+ return TEMP_QUEUE_TYPE;
+ } else {
+ return QUEUE_TYPE;
}
- } else {
- if (destination.isQueue()) {
- if (destination.isTemporary()) {
- return TEMP_QUEUE_ATTRIBUTES_STRING;
- } else {
- return QUEUE_ATTRIBUTES_STRING;
- }
- } else if (destination.isTopic()) {
- if (destination.isTemporary()) {
- return TEMP_TOPIC_ATTRIBUTES_STRING;
- } else {
- return TOPIC_ATTRIBUTES_STRING;
- }
+ } else if (destination.isTopic()) {
+ if (destination.isTemporary()) {
+ return TEMP_TOPIC_TYPE;
+ } else {
+ return TOPIC_TYPE;
}
}
+
return null;
}
http://git-wip-us.apache.org/repos/asf/qpid-jms/blob/0d5adeb0/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/message/AmqpJmsMessageFacade.java
----------------------------------------------------------------------
diff --git a/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/message/AmqpJmsMessageFacade.java b/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/message/AmqpJmsMessageFacade.java
index 4fc0132..5465ccb 100644
--- a/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/message/AmqpJmsMessageFacade.java
+++ b/qpid-jms-client/src/main/java/org/apache/qpid/jms/provider/amqp/message/AmqpJmsMessageFacade.java
@@ -655,7 +655,7 @@ public class AmqpJmsMessageFacade implements JmsMessageFacade {
public void setDestination(JmsDestination destination) {
this.destination = destination;
lazyCreateMessageAnnotations();
- AmqpDestinationHelper.INSTANCE.setToAddressFromDestination(this, destination, connection.isUseByteDestinationTypeAnnotation());
+ AmqpDestinationHelper.INSTANCE.setToAddressFromDestination(this, destination);
}
@Override
@@ -671,7 +671,7 @@ public class AmqpJmsMessageFacade implements JmsMessageFacade {
public void setReplyTo(JmsDestination replyTo) {
this.replyTo = replyTo;
lazyCreateMessageAnnotations();
- AmqpDestinationHelper.INSTANCE.setReplyToAddressFromDestination(this, replyTo, connection.isUseByteDestinationTypeAnnotation());
+ AmqpDestinationHelper.INSTANCE.setReplyToAddressFromDestination(this, replyTo);
}
public void setReplyToGroupId(String replyToGroupId) {
http://git-wip-us.apache.org/repos/asf/qpid-jms/blob/0d5adeb0/qpid-jms-client/src/test/java/org/apache/qpid/jms/integration/MessageIntegrationTest.java
----------------------------------------------------------------------
diff --git a/qpid-jms-client/src/test/java/org/apache/qpid/jms/integration/MessageIntegrationTest.java b/qpid-jms-client/src/test/java/org/apache/qpid/jms/integration/MessageIntegrationTest.java
index dcafdf3..5b54b51 100644
--- a/qpid-jms-client/src/test/java/org/apache/qpid/jms/integration/MessageIntegrationTest.java
+++ b/qpid-jms-client/src/test/java/org/apache/qpid/jms/integration/MessageIntegrationTest.java
@@ -353,90 +353,6 @@ public class MessageIntegrationTest extends QpidJmsTestCase
// --- old string type annotation values --- //
/**
- * Tests that the {@link AmqpMessageSupport#AMQP_TO_ANNOTATION} is set as a string on
- * a sent message to indicate its 'to' address represents a Topic JMSDestination, when
- * the provider has been configured to do so.
- */
- @Test(timeout = 5000)
- public void testSentMessageContainsToTypeAnnotationStringIfConfigured() throws Exception {
- try (TestAmqpPeer testPeer = new TestAmqpPeer(IntegrationTestFixture.PORT);) {
- // Enable the old string destination type annotation values
- Connection connection = testFixture.establishConnecton(testPeer, "?provider.useByteDestinationTypeAnnotation=false");
-
- testPeer.expectBegin(true);
- testPeer.expectSenderAttach();
-
- Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
- String topicName = "myTopic";
-
- MessageHeaderSectionMatcher headersMatcher = new MessageHeaderSectionMatcher(true).withDurable(equalTo(true));
- MessageAnnotationsSectionMatcher msgAnnotationsMatcher = new MessageAnnotationsSectionMatcher(true);
- Symbol annotationKey = AmqpMessageSupport.getSymbol(AmqpMessageSupport.AMQP_TO_ANNOTATION);
- msgAnnotationsMatcher.withEntry(annotationKey, equalTo(AmqpDestinationHelper.TOPIC_ATTRIBUTES_STRING));
-
- MessagePropertiesSectionMatcher propsMatcher = new MessagePropertiesSectionMatcher(true).withTo(equalTo(topicName));
-
- TransferPayloadCompositeMatcher messageMatcher = new TransferPayloadCompositeMatcher();
- messageMatcher.setHeadersMatcher(headersMatcher);
- messageMatcher.setMessageAnnotationsMatcher(msgAnnotationsMatcher);
- messageMatcher.setPropertiesMatcher(propsMatcher);
-
- testPeer.expectTransfer(messageMatcher);
-
- Message message = session.createMessage();
- Topic topic = session.createTopic(topicName);
- MessageProducer producer = session.createProducer(topic);
- producer.send(message);
-
- testPeer.waitForAllHandlersToComplete(2000);
- }
- }
-
- /**
- * Tests that the {@link AmqpMessageSupport#AMQP_REPLY_TO_ANNOTATION} is set as a string on
- * a sent message to indicate its 'reply-to' address represents a Topic JMSDestination, when
- * the provider has been configured to do so.
- */
- @Test(timeout = 5000)
- public void testSentMessageContainsReplyToTypeAnnotationStringIfConfigured() throws Exception {
- try (TestAmqpPeer testPeer = new TestAmqpPeer(IntegrationTestFixture.PORT);) {
- // Enable the old string destination type annotation values
- Connection connection = testFixture.establishConnecton(testPeer, "?provider.useByteDestinationTypeAnnotation=false");
-
- testPeer.expectBegin(true);
- testPeer.expectSenderAttach();
-
- Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
- String queueName = "myQueue";
- String replyTopicName = "myReplyTopic";
-
- MessageHeaderSectionMatcher headersMatcher = new MessageHeaderSectionMatcher(true).withDurable(equalTo(true));
- MessageAnnotationsSectionMatcher msgAnnotationsMatcher = new MessageAnnotationsSectionMatcher(true);
- Symbol annotationKey = AmqpMessageSupport.getSymbol(AmqpMessageSupport.AMQP_REPLY_TO_ANNOTATION);
- msgAnnotationsMatcher.withEntry(annotationKey, equalTo(AmqpDestinationHelper.TOPIC_ATTRIBUTES_STRING));
-
- MessagePropertiesSectionMatcher propsMatcher = new MessagePropertiesSectionMatcher(true).withReplyTo(equalTo(replyTopicName));
-
- TransferPayloadCompositeMatcher messageMatcher = new TransferPayloadCompositeMatcher();
- messageMatcher.setHeadersMatcher(headersMatcher);
- messageMatcher.setMessageAnnotationsMatcher(msgAnnotationsMatcher);
- messageMatcher.setPropertiesMatcher(propsMatcher);
-
- testPeer.expectTransfer(messageMatcher);
-
- Topic replyTopic = session.createTopic(replyTopicName);
- Message message = session.createMessage();
- message.setJMSReplyTo(replyTopic);
-
- Queue queue = session.createQueue(queueName);
- MessageProducer producer = session.createProducer(queue);
- producer.send(message);
-
- testPeer.waitForAllHandlersToComplete(2000);
- }
- }
-
- /**
* Tests that the {@link AmqpMessageSupport#AMQP_TO_ANNOTATION} set on a message to
* indicate its 'to' address represents a Topic results in the JMSDestination object being a
* Topic. Ensure the consumers destination is not used by consuming from a Queue.
http://git-wip-us.apache.org/repos/asf/qpid-jms/blob/0d5adeb0/qpid-jms-client/src/test/java/org/apache/qpid/jms/provider/amqp/message/AmqpDestinationHelperTest.java
----------------------------------------------------------------------
diff --git a/qpid-jms-client/src/test/java/org/apache/qpid/jms/provider/amqp/message/AmqpDestinationHelperTest.java b/qpid-jms-client/src/test/java/org/apache/qpid/jms/provider/amqp/message/AmqpDestinationHelperTest.java
index 7f6a698..ed1353a 100644
--- a/qpid-jms-client/src/test/java/org/apache/qpid/jms/provider/amqp/message/AmqpDestinationHelperTest.java
+++ b/qpid-jms-client/src/test/java/org/apache/qpid/jms/provider/amqp/message/AmqpDestinationHelperTest.java
@@ -17,10 +17,14 @@
package org.apache.qpid.jms.provider.amqp.message;
import static org.apache.qpid.jms.provider.amqp.message.AmqpDestinationHelper.QUEUE_ATTRIBUTES_STRING;
+import static org.apache.qpid.jms.provider.amqp.message.AmqpDestinationHelper.QUEUE_TYPE;
import static org.apache.qpid.jms.provider.amqp.message.AmqpDestinationHelper.REPLY_TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME;
import static org.apache.qpid.jms.provider.amqp.message.AmqpDestinationHelper.TEMP_QUEUE_ATTRIBUTES_STRING;
+import static org.apache.qpid.jms.provider.amqp.message.AmqpDestinationHelper.TEMP_QUEUE_TYPE;
import static org.apache.qpid.jms.provider.amqp.message.AmqpDestinationHelper.TEMP_TOPIC_ATTRIBUTES_STRING;
+import static org.apache.qpid.jms.provider.amqp.message.AmqpDestinationHelper.TEMP_TOPIC_TYPE;
import static org.apache.qpid.jms.provider.amqp.message.AmqpDestinationHelper.TOPIC_ATTRIBUTES_STRING;
+import static org.apache.qpid.jms.provider.amqp.message.AmqpDestinationHelper.TOPIC_TYPE;
import static org.apache.qpid.jms.provider.amqp.message.AmqpDestinationHelper.TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertFalse;
@@ -424,20 +428,20 @@ public class AmqpDestinationHelperTest {
@Test
public void testSetToAddressFromDestinationWithNullDestination() {
AmqpJmsMessageFacade message = Mockito.mock(AmqpJmsMessageFacade.class);
- helper.setToAddressFromDestination(message, null, false);
+ helper.setToAddressFromDestination(message, null);
Mockito.verify(message).setToAddress(null);
Mockito.verify(message).removeMessageAnnotation(TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME);
}
@Test(expected=NullPointerException.class)
public void testSetToAddressFromDestinationWithNullDestinationAndNullMessage() {
- helper.setToAddressFromDestination(null, null, false);
+ helper.setToAddressFromDestination(null, null);
}
@Test(expected=NullPointerException.class)
public void testSetToAddressFromDestinationWithNullMessage() {
JmsDestination destination = new JmsQueue("testAddress");
- helper.setToAddressFromDestination(null, destination, false);
+ helper.setToAddressFromDestination(null, destination);
}
@Test
@@ -446,10 +450,10 @@ public class AmqpDestinationHelperTest {
JmsDestination destination = new JmsQueue("testAddress");
AmqpJmsMessageFacade message = Mockito.mock(AmqpJmsMessageFacade.class);
- helper.setToAddressFromDestination(message, destination, false);
+ helper.setToAddressFromDestination(message, destination);
Mockito.verify(message).setToAddress(testAddress);
- Mockito.verify(message).setMessageAnnotation(TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME, QUEUE_ATTRIBUTES_STRING);
+ Mockito.verify(message).setMessageAnnotation(TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME, QUEUE_TYPE);
}
@Test
@@ -458,10 +462,10 @@ public class AmqpDestinationHelperTest {
JmsDestination destination = new JmsTopic("testAddress");
AmqpJmsMessageFacade message = Mockito.mock(AmqpJmsMessageFacade.class);
- helper.setToAddressFromDestination(message, destination, false);
+ helper.setToAddressFromDestination(message, destination);
Mockito.verify(message).setToAddress(testAddress);
- Mockito.verify(message).setMessageAnnotation(TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME, TOPIC_ATTRIBUTES_STRING);
+ Mockito.verify(message).setMessageAnnotation(TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME, TOPIC_TYPE);
}
@Test
@@ -470,10 +474,10 @@ public class AmqpDestinationHelperTest {
JmsDestination destination = new JmsTemporaryQueue("testAddress");
AmqpJmsMessageFacade message = Mockito.mock(AmqpJmsMessageFacade.class);
- helper.setToAddressFromDestination(message, destination, false);
+ helper.setToAddressFromDestination(message, destination);
Mockito.verify(message).setToAddress(testAddress);
- Mockito.verify(message).setMessageAnnotation(TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME, TEMP_QUEUE_ATTRIBUTES_STRING);
+ Mockito.verify(message).setMessageAnnotation(TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME, TEMP_QUEUE_TYPE);
}
@Test
@@ -482,10 +486,10 @@ public class AmqpDestinationHelperTest {
JmsDestination destination = new JmsTemporaryTopic("testAddress");
AmqpJmsMessageFacade message = Mockito.mock(AmqpJmsMessageFacade.class);
- helper.setToAddressFromDestination(message, destination, false);
+ helper.setToAddressFromDestination(message, destination);
Mockito.verify(message).setToAddress(testAddress);
- Mockito.verify(message).setMessageAnnotation(TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME, TEMP_TOPIC_ATTRIBUTES_STRING);
+ Mockito.verify(message).setMessageAnnotation(TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME, TEMP_TOPIC_TYPE);
}
@Test
@@ -495,7 +499,7 @@ public class AmqpDestinationHelperTest {
Mockito.when(destination.getName()).thenReturn(testAddress);
AmqpJmsMessageFacade message = Mockito.mock(AmqpJmsMessageFacade.class);
- helper.setToAddressFromDestination(message, destination, false);
+ helper.setToAddressFromDestination(message, destination);
Mockito.verify(message).setToAddress(testAddress);
Mockito.verify(message).removeMessageAnnotation(TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME);
@@ -506,20 +510,20 @@ public class AmqpDestinationHelperTest {
@Test
public void testSetReplyToAddressFromDestinationWithNullDestination() {
AmqpJmsMessageFacade message = Mockito.mock(AmqpJmsMessageFacade.class);
- helper.setReplyToAddressFromDestination(message, null, false);
+ helper.setReplyToAddressFromDestination(message, null);
Mockito.verify(message).setReplyToAddress(null);
Mockito.verify(message).removeMessageAnnotation(REPLY_TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME);
}
@Test(expected=NullPointerException.class)
public void testSetReplyToAddressFromDestinationWithNullDestinationAndNullMessage() {
- helper.setReplyToAddressFromDestination(null, null, false);
+ helper.setReplyToAddressFromDestination(null, null);
}
@Test(expected=NullPointerException.class)
public void testSetReplyToAddressFromDestinationWithNullMessage() {
JmsDestination destination = new JmsQueue("testAddress");
- helper.setReplyToAddressFromDestination(null, destination, false);
+ helper.setReplyToAddressFromDestination(null, destination);
}
@Test
@@ -528,10 +532,10 @@ public class AmqpDestinationHelperTest {
JmsDestination destination = new JmsQueue("testAddress");
AmqpJmsMessageFacade message = Mockito.mock(AmqpJmsMessageFacade.class);
- helper.setReplyToAddressFromDestination(message, destination, false);
+ helper.setReplyToAddressFromDestination(message, destination);
Mockito.verify(message).setReplyToAddress(testAddress);
- Mockito.verify(message).setMessageAnnotation(REPLY_TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME, QUEUE_ATTRIBUTES_STRING);
+ Mockito.verify(message).setMessageAnnotation(REPLY_TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME, QUEUE_TYPE);
}
@Test
@@ -540,10 +544,10 @@ public class AmqpDestinationHelperTest {
JmsDestination destination = new JmsTopic("testAddress");
AmqpJmsMessageFacade message = Mockito.mock(AmqpJmsMessageFacade.class);
- helper.setReplyToAddressFromDestination(message, destination, false);
+ helper.setReplyToAddressFromDestination(message, destination);
Mockito.verify(message).setReplyToAddress(testAddress);
- Mockito.verify(message).setMessageAnnotation(REPLY_TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME, TOPIC_ATTRIBUTES_STRING);
+ Mockito.verify(message).setMessageAnnotation(REPLY_TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME, TOPIC_TYPE);
}
@Test
@@ -552,10 +556,10 @@ public class AmqpDestinationHelperTest {
JmsDestination destination = new JmsTemporaryQueue("testAddress");
AmqpJmsMessageFacade message = Mockito.mock(AmqpJmsMessageFacade.class);
- helper.setReplyToAddressFromDestination(message, destination, false);
+ helper.setReplyToAddressFromDestination(message, destination);
Mockito.verify(message).setReplyToAddress(testAddress);
- Mockito.verify(message).setMessageAnnotation(REPLY_TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME, TEMP_QUEUE_ATTRIBUTES_STRING);
+ Mockito.verify(message).setMessageAnnotation(REPLY_TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME, TEMP_QUEUE_TYPE);
}
@Test
@@ -564,10 +568,10 @@ public class AmqpDestinationHelperTest {
JmsDestination destination = new JmsTemporaryTopic("testAddress");
AmqpJmsMessageFacade message = Mockito.mock(AmqpJmsMessageFacade.class);
- helper.setReplyToAddressFromDestination(message, destination, false);
+ helper.setReplyToAddressFromDestination(message, destination);
Mockito.verify(message).setReplyToAddress(testAddress);
- Mockito.verify(message).setMessageAnnotation(REPLY_TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME, TEMP_TOPIC_ATTRIBUTES_STRING);
+ Mockito.verify(message).setMessageAnnotation(REPLY_TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME, TEMP_TOPIC_TYPE);
}
@Test
@@ -577,7 +581,7 @@ public class AmqpDestinationHelperTest {
Mockito.when(destination.getName()).thenReturn(testAddress);
AmqpJmsMessageFacade message = Mockito.mock(AmqpJmsMessageFacade.class);
- helper.setReplyToAddressFromDestination(message, destination, false);
+ helper.setReplyToAddressFromDestination(message, destination);
Mockito.verify(message).setReplyToAddress(testAddress);
Mockito.verify(message).removeMessageAnnotation(REPLY_TO_TYPE_MSG_ANNOTATION_SYMBOL_NAME);
@@ -586,7 +590,7 @@ public class AmqpDestinationHelperTest {
//--------------- Test Support Methods -----------------------------------//
@Test
- public void testSplitAttributeWithExtranerousCommas() throws Exception {
+ public void testSplitAttributeWithExtraneousCommas() throws Exception {
Set<String> set = new HashSet<String>();
set.add(AmqpDestinationHelper.QUEUE_ATTRIBUTE);
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@qpid.apache.org
For additional commands, e-mail: commits-help@qpid.apache.org