git-svn-id: https://svn.apache.org/repos/asf/activemq/trunk@661663 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Robert Davies 2008-05-30 11:44:19 +00:00
parent db4f602e8c
commit 4ecc89eca0
1 changed files with 10 additions and 10 deletions

View File

@ -1091,20 +1091,20 @@ public class ActiveMQConnection implements Connection, TopicConnection, QueueCon
ensureConnectionInfoSent();
ConsumerId consumerId = createConsumerId();
ConsumerInfo info = new ConsumerInfo(consumerId);
info.setDestination(ActiveMQMessageTransformation.transformDestination(destination));
info.setSelector(messageSelector);
info.setPrefetchSize(maxMessages);
info.setNoLocal(noLocal);
info.setDispatchAsync(isDispatchAsync());
ConsumerInfo consumerInfo = new ConsumerInfo(consumerId);
consumerInfo.setDestination(ActiveMQMessageTransformation.transformDestination(destination));
consumerInfo.setSelector(messageSelector);
consumerInfo.setPrefetchSize(maxMessages);
consumerInfo.setNoLocal(noLocal);
consumerInfo.setDispatchAsync(isDispatchAsync());
// Allows the options on the destination to configure the consumerInfo
if (info.getDestination().getOptions() != null) {
Map<String, String> options = new HashMap<String, String>(info.getDestination().getOptions());
IntrospectionSupport.setProperties(info, options, "consumer.");
if (consumerInfo.getDestination().getOptions() != null) {
Map<String, String> options = new HashMap<String, String>(consumerInfo.getDestination().getOptions());
IntrospectionSupport.setProperties(consumerInfo, options, "consumer.");
}
return new ActiveMQConnectionConsumer(this, sessionPool, info);
return new ActiveMQConnectionConsumer(this, sessionPool, consumerInfo);
}
/**