You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by cl...@apache.org on 2017/03/05 21:13:42 UTC
activemq-artemis git commit: last words before PR
Repository: activemq-artemis
Updated Branches:
refs/heads/artemis-1009 0a7eee6f5 -> f9e7ee1dc
last words before PR
Project: http://git-wip-us.apache.org/repos/asf/activemq-artemis/repo
Commit: http://git-wip-us.apache.org/repos/asf/activemq-artemis/commit/f9e7ee1d
Tree: http://git-wip-us.apache.org/repos/asf/activemq-artemis/tree/f9e7ee1d
Diff: http://git-wip-us.apache.org/repos/asf/activemq-artemis/diff/f9e7ee1d
Branch: refs/heads/artemis-1009
Commit: f9e7ee1dcfd75465dcc4fd33e1a10cc73f424f91
Parents: 0a7eee6
Author: Clebert Suconic <cl...@apache.org>
Authored: Sun Mar 5 16:13:36 2017 -0500
Committer: Clebert Suconic <cl...@apache.org>
Committed: Sun Mar 5 16:13:36 2017 -0500
----------------------------------------------------------------------
.../cli/commands/tools/XmlDataExporter.java | 2 --
.../activemq/artemis/api/core/ICoreMessage.java | 3 +++
.../activemq/artemis/api/core/Message.java | 8 +++---
.../artemis/core/message/impl/CoreMessage.java | 11 ++++++---
.../protocol/amqp/broker/AMQPMessage.java | 26 ++++++++++++++++----
.../amqp/converter/AMQPMessageSupport.java | 2 +-
.../core/protocol/mqtt/MQTTPublishManager.java | 1 -
.../protocol/openwire/OpenWireConnection.java | 3 ---
.../openwire/OpenWireMessageConverter.java | 1 -
.../openwire/OpenWireProtocolManager.java | 1 -
.../core/protocol/openwire/OpenwireMessage.java | 5 ----
.../core/server/cluster/impl/BridgeImpl.java | 1 -
.../artemis/core/server/impl/QueueImpl.java | 5 +---
.../core/server/impl/ServerSessionImpl.java | 20 +++++++--------
.../impl/ScheduledDeliveryHandlerTest.java | 5 ----
.../integration/client/AcknowledgeTest.java | 5 ----
.../storage/PersistMultiThreadTest.java | 1 -
17 files changed, 47 insertions(+), 53 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/f9e7ee1d/artemis-cli/src/main/java/org/apache/activemq/artemis/cli/commands/tools/XmlDataExporter.java
----------------------------------------------------------------------
diff --git a/artemis-cli/src/main/java/org/apache/activemq/artemis/cli/commands/tools/XmlDataExporter.java b/artemis-cli/src/main/java/org/apache/activemq/artemis/cli/commands/tools/XmlDataExporter.java
index 4638df7..d2f6204 100644
--- a/artemis-cli/src/main/java/org/apache/activemq/artemis/cli/commands/tools/XmlDataExporter.java
+++ b/artemis-cli/src/main/java/org/apache/activemq/artemis/cli/commands/tools/XmlDataExporter.java
@@ -381,8 +381,6 @@ public final class XmlDataExporter extends OptionalLocking {
*/
private void printPagedMessagesAsXML() {
try {
-
- // TODO-now: fix encodings
ScheduledExecutorService scheduled = Executors.newScheduledThreadPool(1, ActiveMQThreadFactory.defaultThreadFactory());
final ExecutorService executor = Executors.newFixedThreadPool(10, ActiveMQThreadFactory.defaultThreadFactory());
ExecutorFactory executorFactory = new ExecutorFactory() {
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/f9e7ee1d/artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/ICoreMessage.java
----------------------------------------------------------------------
diff --git a/artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/ICoreMessage.java b/artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/ICoreMessage.java
index 9a58819..779470e 100644
--- a/artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/ICoreMessage.java
+++ b/artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/ICoreMessage.java
@@ -62,6 +62,9 @@ public interface ICoreMessage extends Message {
int getEndOfBodyPosition();
+ /** Used on large messages treatment */
+ void copyHeadersAndProperties(final Message msg);
+
/**
* @return Returns the message in Map form, useful when encoding to JSON
*/
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/f9e7ee1d/artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/Message.java
----------------------------------------------------------------------
diff --git a/artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/Message.java b/artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/Message.java
index 496a532..c7a831b 100644
--- a/artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/Message.java
+++ b/artemis-core-client/src/main/java/org/apache/activemq/artemis/api/core/Message.java
@@ -221,6 +221,10 @@ public interface Message {
* Return null if not scheduled. */
Long getScheduledDeliveryTime();
+ default Message setScheduledDeliveryTime(Long time) {
+ return this;
+ }
+
/** Context can be used by the application server to inject extra control, like a protocol specific on the server.
* There is only one per Object, use it wisely!
*
@@ -292,8 +296,6 @@ public interface Message {
Message setUserID(Object userID);
- void copyHeadersAndProperties(final Message msg);
-
/**
* Returns whether this message is durable or not.
*/
@@ -382,7 +384,6 @@ public interface Message {
/**
* it will translate a property named HDR_DUPLICATE_DETECTION_ID.
- * TODO-NOW: this can probably be replaced by an utility.
* @return
*/
default byte[] getDuplicateIDBytes() {
@@ -403,7 +404,6 @@ public interface Message {
/**
* it will translate a property named HDR_DUPLICATE_DETECTION_ID.
- * TODO-NOW: this can probably be replaced by an utility.
* @return
*/
default Object getDuplicateProperty() {
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/f9e7ee1d/artemis-core-client/src/main/java/org/apache/activemq/artemis/core/message/impl/CoreMessage.java
----------------------------------------------------------------------
diff --git a/artemis-core-client/src/main/java/org/apache/activemq/artemis/core/message/impl/CoreMessage.java b/artemis-core-client/src/main/java/org/apache/activemq/artemis/core/message/impl/CoreMessage.java
index 1e4087f..60cbf59 100644
--- a/artemis-core-client/src/main/java/org/apache/activemq/artemis/core/message/impl/CoreMessage.java
+++ b/artemis-core-client/src/main/java/org/apache/activemq/artemis/core/message/impl/CoreMessage.java
@@ -214,6 +214,7 @@ public class CoreMessage extends RefCountMessage implements ICoreMessage {
@Override
public Long getScheduledDeliveryTime() {
+ checkProperties();
Object property = getObjectProperty(Message.HDR_SCHEDULED_DELIVERY_TIME);
if (property != null && property instanceof Number) {
@@ -224,6 +225,13 @@ public class CoreMessage extends RefCountMessage implements ICoreMessage {
}
@Override
+ public CoreMessage setScheduledDeliveryTime(Long time) {
+ checkProperties();
+ putLongProperty(Message.HDR_SCHEDULED_DELIVERY_TIME, time);
+ return this;
+ }
+
+ @Override
public InputStream getBodyInputStream() {
return null;
}
@@ -311,9 +319,6 @@ public class CoreMessage extends RefCountMessage implements ICoreMessage {
if (msg instanceof CoreMessage) {
properties = ((CoreMessage)msg).getTypedProperties();
- } else {
- // TODO-now: copy stuff
- logger.warn("Must implement copyHeaderAndProperties for other messages");
}
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/f9e7ee1d/artemis-protocols/artemis-amqp-protocol/src/main/java/org/apache/activemq/artemis/protocol/amqp/broker/AMQPMessage.java
----------------------------------------------------------------------
diff --git a/artemis-protocols/artemis-amqp-protocol/src/main/java/org/apache/activemq/artemis/protocol/amqp/broker/AMQPMessage.java b/artemis-protocols/artemis-amqp-protocol/src/main/java/org/apache/activemq/artemis/protocol/amqp/broker/AMQPMessage.java
index 12218f8..41bc37a 100644
--- a/artemis-protocols/artemis-amqp-protocol/src/main/java/org/apache/activemq/artemis/protocol/amqp/broker/AMQPMessage.java
+++ b/artemis-protocols/artemis-amqp-protocol/src/main/java/org/apache/activemq/artemis/protocol/amqp/broker/AMQPMessage.java
@@ -34,6 +34,7 @@ import org.apache.activemq.artemis.api.core.RoutingType;
import org.apache.activemq.artemis.api.core.SimpleString;
import org.apache.activemq.artemis.core.persistence.Persister;
import org.apache.activemq.artemis.protocol.amqp.converter.AMQPConverter;
+import org.apache.activemq.artemis.protocol.amqp.converter.AMQPMessageSupport;
import org.apache.activemq.artemis.protocol.amqp.util.NettyWritable;
import org.apache.activemq.artemis.protocol.amqp.util.TLSEncode;
import org.apache.activemq.artemis.utils.DataConstants;
@@ -186,6 +187,19 @@ public class AMQPMessage extends RefCountMessage {
return null;
}
+
+ private void setSymbol(String symbol, Object value) {
+ setSymbol(Symbol.getSymbol(symbol), value);
+ }
+
+ private void setSymbol(Symbol symbol, Object value) {
+ MessageAnnotations annotations = getMessageAnnotations();
+ Map mapAnnotations = annotations != null ? annotations.getValue() : null;
+ if (mapAnnotations != null) {
+ mapAnnotations.put(symbol, value);
+ }
+ }
+
@Override
public RoutingType getRouteType() {
@@ -228,6 +242,13 @@ public class AMQPMessage extends RefCountMessage {
}
@Override
+ public AMQPMessage setScheduledDeliveryTime(Long time) {
+ parseHeaders();
+ setSymbol(AMQPMessageSupport.JMS_DELIVERY_TIME, time);
+ return this;
+ }
+
+ @Override
public Persister<org.apache.activemq.artemis.api.core.Message> getPersister() {
return AMQPMessagePersister.getInstance();
}
@@ -384,11 +405,6 @@ public class AMQPMessage extends RefCountMessage {
}
@Override
- public void copyHeadersAndProperties(org.apache.activemq.artemis.api.core.Message msg) {
-
- }
-
- @Override
public boolean isDurable() {
if (getHeader() != null && getHeader().getDurable() != null) {
return getHeader().getDurable().booleanValue();
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/f9e7ee1d/artemis-protocols/artemis-amqp-protocol/src/main/java/org/apache/activemq/artemis/protocol/amqp/converter/AMQPMessageSupport.java
----------------------------------------------------------------------
diff --git a/artemis-protocols/artemis-amqp-protocol/src/main/java/org/apache/activemq/artemis/protocol/amqp/converter/AMQPMessageSupport.java b/artemis-protocols/artemis-amqp-protocol/src/main/java/org/apache/activemq/artemis/protocol/amqp/converter/AMQPMessageSupport.java
index 351c1a6..0dd54db 100644
--- a/artemis-protocols/artemis-amqp-protocol/src/main/java/org/apache/activemq/artemis/protocol/amqp/converter/AMQPMessageSupport.java
+++ b/artemis-protocols/artemis-amqp-protocol/src/main/java/org/apache/activemq/artemis/protocol/amqp/converter/AMQPMessageSupport.java
@@ -62,7 +62,7 @@ public final class AMQPMessageSupport {
/**
* Attribute used to mark the Application defined delivery time assigned to the message
*/
- public static final String JMS_DELIVERY_TIME = "x-opt-delivery-time";
+ public static final Symbol JMS_DELIVERY_TIME = Symbol.getSymbol("x-opt-delivery-time");
/**
* Value mapping for JMS_MSG_TYPE which indicates the message is a generic JMS Message
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/f9e7ee1d/artemis-protocols/artemis-mqtt-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/mqtt/MQTTPublishManager.java
----------------------------------------------------------------------
diff --git a/artemis-protocols/artemis-mqtt-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/mqtt/MQTTPublishManager.java b/artemis-protocols/artemis-mqtt-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/mqtt/MQTTPublishManager.java
index 67ef258..553521b 100644
--- a/artemis-protocols/artemis-mqtt-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/mqtt/MQTTPublishManager.java
+++ b/artemis-protocols/artemis-mqtt-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/mqtt/MQTTPublishManager.java
@@ -121,7 +121,6 @@ public class MQTTPublishManager {
} else {
int qos = decideQoS(message, consumer);
if (qos == 0) {
- // TODO-now: fix encoding
sendServerMessage((int) message.getMessageID(), message, deliveryCount, qos);
session.getServerSession().acknowledge(consumer.getID(), message.getMessageID());
} else if (qos == 1 || qos == 2) {
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/f9e7ee1d/artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/OpenWireConnection.java
----------------------------------------------------------------------
diff --git a/artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/OpenWireConnection.java b/artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/OpenWireConnection.java
index 5f408a6..46fe372 100644
--- a/artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/OpenWireConnection.java
+++ b/artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/OpenWireConnection.java
@@ -187,7 +187,6 @@ public class OpenWireConnection extends AbstractRemotingConnection implements Se
private AtomicBoolean disableTtl = new AtomicBoolean(false);
- // TODO-NOW: check on why there are two connections created for every createConnection on the client.
public OpenWireConnection(Connection connection,
ActiveMQServer server,
Executor executor,
@@ -1060,8 +1059,6 @@ public class OpenWireConnection extends AbstractRemotingConnection implements Se
@Override
public Response processRemoveProducer(ProducerId id) throws Exception {
-
- // TODO-now: proper implement this method
return null;
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/f9e7ee1d/artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/OpenWireMessageConverter.java
----------------------------------------------------------------------
diff --git a/artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/OpenWireMessageConverter.java b/artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/OpenWireMessageConverter.java
index 76e50ef..3808363 100644
--- a/artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/OpenWireMessageConverter.java
+++ b/artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/OpenWireMessageConverter.java
@@ -427,7 +427,6 @@ public class OpenWireMessageConverter implements MessageConverter<OpenwireMessag
public static MessageDispatch createMessageDispatch(MessageReference reference,
ICoreMessage message,
AMQConsumer consumer) throws IOException, JMSException {
- // TODO-now: use new Encode here
ActiveMQMessage amqMessage = toAMQMessage(reference, message, consumer.getMarshaller(), consumer.getOpenwireDestination());
//we can use core message id for sequenceId
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/f9e7ee1d/artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/OpenWireProtocolManager.java
----------------------------------------------------------------------
diff --git a/artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/OpenWireProtocolManager.java b/artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/OpenWireProtocolManager.java
index 4292fe5..c0affb6 100644
--- a/artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/OpenWireProtocolManager.java
+++ b/artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/OpenWireProtocolManager.java
@@ -136,7 +136,6 @@ public class OpenWireProtocolManager implements ProtocolManager<Interceptor>, Cl
final ClusterManager clusterManager = this.server.getClusterManager();
- // TODO-NOW: use a property name for the cluster connection
ClusterConnection cc = clusterManager.getDefaultConnection(null);
if (cc != null) {
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/f9e7ee1d/artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/OpenwireMessage.java
----------------------------------------------------------------------
diff --git a/artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/OpenwireMessage.java b/artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/OpenwireMessage.java
index 186900b..5793d58 100644
--- a/artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/OpenwireMessage.java
+++ b/artemis-protocols/artemis-openwire-protocol/src/main/java/org/apache/activemq/artemis/core/protocol/openwire/OpenwireMessage.java
@@ -138,11 +138,6 @@ public class OpenwireMessage implements Message {
}
@Override
- public void copyHeadersAndProperties(Message msg) {
-
- }
-
- @Override
public boolean isDurable() {
return false;
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/f9e7ee1d/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/impl/BridgeImpl.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/impl/BridgeImpl.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/impl/BridgeImpl.java
index f7a3540..fe43532 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/impl/BridgeImpl.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/cluster/impl/BridgeImpl.java
@@ -695,7 +695,6 @@ public class BridgeImpl implements Bridge, SessionFailureListener, SendAcknowled
}
try {
- // TODO-now: replace this
producer.send(dest, message);
} catch (final ActiveMQException e) {
ActiveMQServerLogger.LOGGER.bridgeUnableToSendMessage(e, ref);
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/f9e7ee1d/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/QueueImpl.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/QueueImpl.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/QueueImpl.java
index bdbc57b..f0f8e97 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/QueueImpl.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/QueueImpl.java
@@ -1242,9 +1242,7 @@ public class QueueImpl implements Queue {
List<MessageReference> scheduledMessages = scheduledDeliveryHandler.cancel(null);
if (scheduledMessages != null && scheduledMessages.size() > 0) {
for (MessageReference ref : scheduledMessages) {
-
- // TODO-now remove this, use something on Reference
-// ref.getMessage().putLongProperty(Message.HDR_SCHEDULED_DELIVERY_TIME, ref.getScheduledDeliveryTime());
+ ref.getMessage().setScheduledDeliveryTime(ref.getScheduledDeliveryTime());
ref.setScheduledDeliveryTime(0);
}
this.addHead(scheduledMessages, true);
@@ -2364,7 +2362,6 @@ public class QueueImpl implements Queue {
String targetNodeID;
Binding targetBinding;
- // TODO-now: this needs to go away
// remove the old route
for (SimpleString propName : copyMessage.getPropertyNames()) {
if (propName.startsWith(Message.HDR_ROUTE_TO_IDS)) {
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/f9e7ee1d/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerSessionImpl.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerSessionImpl.java b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerSessionImpl.java
index a85afe6..3750455 100644
--- a/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerSessionImpl.java
+++ b/artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ServerSessionImpl.java
@@ -166,7 +166,7 @@ public class ServerSessionImpl implements ServerSession, FailureListener {
private final OperationContext context;
// Session's usage should be by definition single threaded, hence it's not needed to use a concurrentHashMap here
- protected final Map<SimpleString, Pair<UUID, AtomicLong>> targetAddressInfos = new HashMap<>();
+ protected final Map<SimpleString, Pair<Object, AtomicLong>> targetAddressInfos = new HashMap<>();
private final long creationTime = System.currentTimeMillis();
@@ -1410,7 +1410,7 @@ public class ServerSessionImpl implements ServerSession, FailureListener {
@Override
public String[] getTargetAddresses() {
- Map<SimpleString, Pair<UUID, AtomicLong>> copy = cloneTargetAddresses();
+ Map<SimpleString, Pair<Object, AtomicLong>> copy = cloneTargetAddresses();
Iterator<SimpleString> iter = copy.keySet().iterator();
int num = copy.keySet().size();
String[] addresses = new String[num];
@@ -1424,7 +1424,7 @@ public class ServerSessionImpl implements ServerSession, FailureListener {
@Override
public String getLastSentMessageID(String address) {
- Pair<UUID, AtomicLong> value = targetAddressInfos.get(SimpleString.toSimpleString(address));
+ Pair<Object, AtomicLong> value = targetAddressInfos.get(SimpleString.toSimpleString(address));
if (value != null) {
return value.getA().toString();
} else {
@@ -1443,9 +1443,9 @@ public class ServerSessionImpl implements ServerSession, FailureListener {
@Override
public void describeProducersInfo(JsonArrayBuilder array) throws Exception {
- Map<SimpleString, Pair<UUID, AtomicLong>> targetCopy = cloneTargetAddresses();
+ Map<SimpleString, Pair<Object, AtomicLong>> targetCopy = cloneTargetAddresses();
- for (Map.Entry<SimpleString, Pair<UUID, AtomicLong>> entry : targetCopy.entrySet()) {
+ for (Map.Entry<SimpleString, Pair<Object, AtomicLong>> entry : targetCopy.entrySet()) {
String uuid = null;
if (entry.getValue().getA() != null) {
uuid = entry.getValue().getA().toString();
@@ -1523,7 +1523,7 @@ public class ServerSessionImpl implements ServerSession, FailureListener {
private void installJMSHooks() {
}
- private Map<SimpleString, Pair<UUID, AtomicLong>> cloneTargetAddresses() {
+ private Map<SimpleString, Pair<Object, AtomicLong>> cloneTargetAddresses() {
return new HashMap<>(targetAddressInfos);
}
@@ -1662,14 +1662,12 @@ public class ServerSessionImpl implements ServerSession, FailureListener {
result = postOffice.route(msg, routingContext, direct);
- Pair<UUID, AtomicLong> value = targetAddressInfos.get(msg.getAddressSimpleString());
+ Pair<Object, AtomicLong> value = targetAddressInfos.get(msg.getAddressSimpleString());
if (value == null) {
- // TODO-now: userID
-// targetAddressInfos.put(msg.getAddressSimpleString(), new Pair<>((UUID)msg.getUserID(), new AtomicLong(1)));
+ targetAddressInfos.put(msg.getAddressSimpleString(), new Pair<>(msg.getUserID(), new AtomicLong(1)));
} else {
- // TODO-now: userID
- value.setA((UUID)msg.getUserID());
+ value.setA(msg.getUserID());
value.getB().incrementAndGet();
}
} finally {
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/f9e7ee1d/artemis-server/src/test/java/org/apache/activemq/artemis/core/server/impl/ScheduledDeliveryHandlerTest.java
----------------------------------------------------------------------
diff --git a/artemis-server/src/test/java/org/apache/activemq/artemis/core/server/impl/ScheduledDeliveryHandlerTest.java b/artemis-server/src/test/java/org/apache/activemq/artemis/core/server/impl/ScheduledDeliveryHandlerTest.java
index 2bd8cb2..1569822 100644
--- a/artemis-server/src/test/java/org/apache/activemq/artemis/core/server/impl/ScheduledDeliveryHandlerTest.java
+++ b/artemis-server/src/test/java/org/apache/activemq/artemis/core/server/impl/ScheduledDeliveryHandlerTest.java
@@ -763,11 +763,6 @@ public class ScheduledDeliveryHandlerTest extends Assert {
}
@Override
- public void copyHeadersAndProperties(Message msg) {
-
- }
-
- @Override
public void receiveBuffer(ByteBuf buffer) {
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/f9e7ee1d/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/client/AcknowledgeTest.java
----------------------------------------------------------------------
diff --git a/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/client/AcknowledgeTest.java b/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/client/AcknowledgeTest.java
index 042effd..d93807f 100644
--- a/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/client/AcknowledgeTest.java
+++ b/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/client/AcknowledgeTest.java
@@ -415,11 +415,6 @@ public class AcknowledgeTest extends ActiveMQTestBase {
}
@Override
- public void copyHeadersAndProperties(Message msg) {
-
- }
-
- @Override
public void messageChanged() {
}
http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/f9e7ee1d/tests/performance-tests/src/test/java/org/apache/activemq/artemis/tests/performance/storage/PersistMultiThreadTest.java
----------------------------------------------------------------------
diff --git a/tests/performance-tests/src/test/java/org/apache/activemq/artemis/tests/performance/storage/PersistMultiThreadTest.java b/tests/performance-tests/src/test/java/org/apache/activemq/artemis/tests/performance/storage/PersistMultiThreadTest.java
index 0c4dbf5..da9e8cd 100644
--- a/tests/performance-tests/src/test/java/org/apache/activemq/artemis/tests/performance/storage/PersistMultiThreadTest.java
+++ b/tests/performance-tests/src/test/java/org/apache/activemq/artemis/tests/performance/storage/PersistMultiThreadTest.java
@@ -189,7 +189,6 @@ public class PersistMultiThreadTest extends ActiveMQTestBase {
private void storeMessage(long txID, long id) throws Exception {
Message message = new CoreMessage(id, 10 * 1024);
- // TODO-now: fix this
message.setContext(fakePagingStore);
message.getBodyBuffer().writeBytes(new byte[104]);