Author: igarashitm
Date: 2011-09-21 21:37:18 -0400 (Wed, 21 Sep 2011)
New Revision: 11395
Added:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/impl/wireformat/SessionUniqueAddMetaDataMessage.java
Modified:
branches/HORNETQ-316_for_2_2_EAP/
branches/HORNETQ-316_for_2_2_EAP/examples/common/config/hornetq-example-beans.xml
branches/HORNETQ-316_for_2_2_EAP/examples/common/src/org/hornetq/common/example/SpawnedVMSupport.java
branches/HORNETQ-316_for_2_2_EAP/examples/core/microcontainer/
branches/HORNETQ-316_for_2_2_EAP/examples/javaee/common/config/ant.properties
branches/HORNETQ-316_for_2_2_EAP/examples/javaee/ejb-jms-transaction/build.xml
branches/HORNETQ-316_for_2_2_EAP/examples/javaee/jca-remote/server0/hornetq-jms.xml
branches/HORNETQ-316_for_2_2_EAP/examples/javaee/jca-remote/server0/hornetq-users.xml
branches/HORNETQ-316_for_2_2_EAP/examples/javaee/mdb-cmt-setrollbackonly/readme.html
branches/HORNETQ-316_for_2_2_EAP/examples/javaee/mdb-cmt-tx-required/readme.html
branches/HORNETQ-316_for_2_2_EAP/examples/jms/browser/server0/hornetq-beans.xml
branches/HORNETQ-316_for_2_2_EAP/examples/jms/browser/server0/hornetq-jms.xml
branches/HORNETQ-316_for_2_2_EAP/examples/jms/browser/server0/hornetq-users.xml
branches/HORNETQ-316_for_2_2_EAP/examples/jms/dead-letter/server0/hornetq-users.xml
branches/HORNETQ-316_for_2_2_EAP/examples/jms/durable-subscription/server0/hornetq-jms.xml
branches/HORNETQ-316_for_2_2_EAP/examples/jms/durable-subscription/server0/hornetq-users.xml
branches/HORNETQ-316_for_2_2_EAP/examples/jms/paging/server0/hornetq-jms.xml
branches/HORNETQ-316_for_2_2_EAP/examples/jms/paging/server0/hornetq-users.xml
branches/HORNETQ-316_for_2_2_EAP/examples/jms/queue-requestor/server0/hornetq-jms.xml
branches/HORNETQ-316_for_2_2_EAP/examples/jms/queue-requestor/server0/hornetq-users.xml
branches/HORNETQ-316_for_2_2_EAP/examples/jms/queue/server0/hornetq-jms.xml
branches/HORNETQ-316_for_2_2_EAP/examples/jms/queue/server0/hornetq-users.xml
branches/HORNETQ-316_for_2_2_EAP/examples/jms/request-reply/server0/hornetq-jms.xml
branches/HORNETQ-316_for_2_2_EAP/examples/jms/request-reply/server0/hornetq-users.xml
branches/HORNETQ-316_for_2_2_EAP/examples/jms/temp-queue/server0/hornetq-jms.xml
branches/HORNETQ-316_for_2_2_EAP/examples/jms/temp-queue/server0/hornetq-users.xml
branches/HORNETQ-316_for_2_2_EAP/examples/jms/topic-selector-example1/
branches/HORNETQ-316_for_2_2_EAP/examples/jms/topic-selector-example1/src/org/hornetq/jms/example/TopicSelectorExample1.java
branches/HORNETQ-316_for_2_2_EAP/examples/jms/topic-selector-example2/
branches/HORNETQ-316_for_2_2_EAP/examples/jms/topic-selector-example2/src/org/hornetq/jms/example/TopicSelectorExample2.java
branches/HORNETQ-316_for_2_2_EAP/examples/jms/topic/server0/hornetq-jms.xml
branches/HORNETQ-316_for_2_2_EAP/examples/jms/topic/server0/hornetq-users.xml
branches/HORNETQ-316_for_2_2_EAP/examples/jms/transactional/server0/hornetq-jms.xml
branches/HORNETQ-316_for_2_2_EAP/examples/jms/xa-send/
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/api/core/HornetQException.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/api/core/client/ClientSession.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/api/jms/management/SubscriptionInfo.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/buffers/
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/client/impl/ClientSessionImpl.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/client/impl/DelegatingSession.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/client/impl/ServerLocatorImpl.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/cluster/DiscoveryGroup.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/cluster/DiscoveryListener.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/cluster/impl/DiscoveryGroupImpl.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/journal/LoaderCallback.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/journal/impl/JournalReaderCallback.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/persistence/impl/journal/LargeServerMessageImpl.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/persistence/impl/nullpm/NullStorageLargeServerMessage.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/ServerSessionPacketHandler.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/impl/PacketDecoder.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/impl/PacketImpl.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/impl/wireformat/SessionAddMetaDataMessageV2.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/impl/wireformat/SessionContinuationMessage.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/remoting/server/impl/RemotingServiceImpl.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/server/HornetQServer.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/server/ServerSession.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/server/impl/HornetQServerImpl.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/server/impl/ServerSessionImpl.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/server/management/ManagementService.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/server/management/impl/ManagementServiceImpl.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/jms/client/HornetQConnection.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/jms/server/management/JMSManagementService.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/jms/server/management/impl/JMSManagementServiceImpl.java
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/utils/UTF8Util.java
branches/HORNETQ-316_for_2_2_EAP/tests/config/ConfigurationTest-defaults.xml
branches/HORNETQ-316_for_2_2_EAP/tests/jms-tests/config/hornetq-beans.xml
branches/HORNETQ-316_for_2_2_EAP/tests/jms-tests/config/hornetq-configuration.xml
branches/HORNETQ-316_for_2_2_EAP/tests/jms-tests/config/hornetq-jms.xml
branches/HORNETQ-316_for_2_2_EAP/tests/jms-tests/config/hornetq-queues.xml
branches/HORNETQ-316_for_2_2_EAP/tests/jms-tests/config/hornetq-users.xml
branches/HORNETQ-316_for_2_2_EAP/tests/jms-tests/config/jndi.properties
branches/HORNETQ-316_for_2_2_EAP/tests/jms-tests/src/org/hornetq/jms/tests/ConnectionTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/jms-tests/src/org/hornetq/jms/tests/message/MessageHeaderTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/AckBatchSizeTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/AcknowledgeTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/AutogroupIdTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/CommitRollbackTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/ConsumerCloseTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/ConsumerRoundRobinTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/ConsumerTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/ConsumerWindowSizeTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/DeliveryOrderTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/LargeMessageTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/MessageCounterTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/MessageHandlerTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/MessageRateTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/PagingTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/ProducerCloseTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/QueueBrowserTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/ReceiveTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/RequestorTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/RoutingTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/SessionCloseTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/SessionCreateAndDeleteQueueTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/SessionCreateConsumerTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/SessionCreateProducerTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/SessionFactoryTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/SessionSendAcknowledgementHandlerTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/SessionStopStartTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/SessionTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/TransactionalSendTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/cluster/distribution/ClusterTestBase.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/cluster/topology/TopologyClusterTestBase.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/jms/server/management/TopicControlTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/jms/server/management/TopicControlUsingJMSTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/journal/NIOJournalCompactTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/management/SecurityManagementTestBase.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/stress/paging/PageStressTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/unit/core/asyncio/AsynchronousFileTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/unit/core/asyncio/MultiThreadAsynchronousFileTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/unit/core/config/impl/DefaultsFileConfigurationTest.java
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/unit/core/paging/impl/PagingManagerImplTest.java
Log:
merge r11373-r11394 from branches/Branch_2_2_EAP
Property changes on: branches/HORNETQ-316_for_2_2_EAP
___________________________________________________________________
Added: svn:mergeinfo
+ /branches/Branch_2_2_EAP:11373-11394
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/common/config/hornetq-example-beans.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/common/src/org/hornetq/common/example/SpawnedVMSupport.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on: branches/HORNETQ-316_for_2_2_EAP/examples/core/microcontainer
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/javaee/common/config/ant.properties
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/javaee/ejb-jms-transaction/build.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/javaee/jca-remote/server0/hornetq-jms.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/javaee/jca-remote/server0/hornetq-users.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/javaee/mdb-cmt-setrollbackonly/readme.html
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/javaee/mdb-cmt-tx-required/readme.html
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/browser/server0/hornetq-beans.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/browser/server0/hornetq-jms.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/browser/server0/hornetq-users.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/dead-letter/server0/hornetq-users.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/durable-subscription/server0/hornetq-jms.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/durable-subscription/server0/hornetq-users.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/paging/server0/hornetq-jms.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/paging/server0/hornetq-users.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/queue/server0/hornetq-jms.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/queue/server0/hornetq-users.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/queue-requestor/server0/hornetq-jms.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/queue-requestor/server0/hornetq-users.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/request-reply/server0/hornetq-jms.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/request-reply/server0/hornetq-users.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/temp-queue/server0/hornetq-jms.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/temp-queue/server0/hornetq-users.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/topic/server0/hornetq-jms.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/topic/server0/hornetq-users.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/topic-selector-example1
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/topic-selector-example1/src/org/hornetq/jms/example/TopicSelectorExample1.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/topic-selector-example2
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/topic-selector-example2/src/org/hornetq/jms/example/TopicSelectorExample2.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/examples/jms/transactional/server0/hornetq-jms.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on: branches/HORNETQ-316_for_2_2_EAP/examples/jms/xa-send
___________________________________________________________________
Deleted: svn:mergeinfo
-
Modified:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/api/core/HornetQException.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/api/core/HornetQException.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/api/core/HornetQException.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -135,6 +135,12 @@
public static final int DUPLICATE_ID_REJECTED = 113;
+ /**
+ * A Session Metadata was set in duplication
+ */
+ public static final int DUPLICATE_METADATA = 114;
+
+
// Native Error codes ----------------------------------------------
/**
Modified:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/api/core/client/ClientSession.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/api/core/client/ClientSession.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/api/core/client/ClientSession.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -569,6 +569,15 @@
void addMetaData(String key, String data) throws HornetQException;
/**
+ * Attach any metadata to the session. Throws an exception if there's already a
metadata available.
+ * You can use this metadata to ensure that there is no other session with the same
meta-data you are passing as an argument.
+ * This is useful to simulate unique client-ids, where you may want to avoid multiple
instances of your client application connected.
+ *
+ * @throws HornetQException
+ */
+ void addUniqueMetaData(String key, String data) throws HornetQException;
+
+ /**
* Attach any metadata to the session.
* Sends a Metadata using the older version
* @deprecated Use {@link ClientSession#addMetaData(String, String)}
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/api/jms/management/SubscriptionInfo.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on: branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/buffers
___________________________________________________________________
Deleted: svn:mergeinfo
-
Modified:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/client/impl/ClientSessionImpl.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/client/impl/ClientSessionImpl.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/client/impl/ClientSessionImpl.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -65,6 +65,7 @@
import
org.hornetq.core.protocol.core.impl.wireformat.SessionRequestProducerCreditsMessage;
import org.hornetq.core.protocol.core.impl.wireformat.SessionSendContinuationMessage;
import org.hornetq.core.protocol.core.impl.wireformat.SessionSendMessage;
+import org.hornetq.core.protocol.core.impl.wireformat.SessionUniqueAddMetaDataMessage;
import org.hornetq.core.protocol.core.impl.wireformat.SessionXACommitMessage;
import org.hornetq.core.protocol.core.impl.wireformat.SessionXAEndMessage;
import org.hornetq.core.protocol.core.impl.wireformat.SessionXAForgetMessage;
@@ -1146,6 +1147,11 @@
}
channel.sendBlocking(new SessionAddMetaDataMessageV2(key, data));
}
+
+ public void addUniqueMetaData(String key, String data) throws HornetQException
+ {
+ channel.sendBlocking(new SessionUniqueAddMetaDataMessage(key, data));
+ }
public ClientSessionFactoryInternal getSessionFactory()
{
Modified:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/client/impl/DelegatingSession.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/client/impl/DelegatingSession.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/client/impl/DelegatingSession.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -593,4 +593,13 @@
return session.getChannel();
}
+ /* (non-Javadoc)
+ * @see org.hornetq.api.core.client.ClientSession#addUniqueMetaData(java.lang.String,
java.lang.String)
+ */
+ public void addUniqueMetaData(String key, String data) throws HornetQException
+ {
+ session.addUniqueMetaData(key, data);
+
+ }
+
}
Modified:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/client/impl/ServerLocatorImpl.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/client/impl/ServerLocatorImpl.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/client/impl/ServerLocatorImpl.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -165,7 +165,7 @@
private Executor startExecutor;
private static ScheduledExecutorService globalScheduledThreadPool;
-
+
private AfterConnectInternalListener afterConnectListener;
private String groupID;
@@ -549,7 +549,7 @@
}
});
}
-
+
public Executor getExecutor()
{
return startExecutor;
@@ -592,7 +592,7 @@
{
return afterConnectListener;
}
-
+
public boolean isClosed()
{
return closed || closing;
@@ -1115,7 +1115,7 @@
{
return identity;
}
-
+
public void setIdentity(String identity)
{
this.identity = identity;
@@ -1287,15 +1287,17 @@
{
log.debug("nodeDown " + this + " nodeID=" + nodeID + "
as being down", new Exception("trace"));
}
-
- if (!(isClusterConnection() && nodeID.equals(this.getNodeID())) &&
topology.removeMember(eventTime, nodeID))
+
+ if (topology.removeMember(eventTime, nodeID))
{
if (topology.isEmpty())
{
// Resetting the topology to its original condition as it was brand new
- topologyArray = null;
-
- receivedTopology = false;
+ synchronized (this)
+ {
+ topologyArray = null;
+ receivedTopology = false;
+ }
}
else
{
@@ -1406,7 +1408,7 @@
for (DiscoveryEntry entry : newConnectors)
{
this.initialConnectors[count++] = entry.getConnector();
-
+
if (topology != null && topology.getMember(entry.getNodeID()) == null)
{
TopologyMember member = new TopologyMember(entry.getConnector(), null);
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/cluster/DiscoveryGroup.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/cluster/DiscoveryListener.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Modified:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/cluster/impl/DiscoveryGroupImpl.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/cluster/impl/DiscoveryGroupImpl.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/cluster/impl/DiscoveryGroupImpl.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -171,13 +171,20 @@
synchronized (waitLock)
{
- waitLock.notify();
+ waitLock.notifyAll();
}
- socket.close();
+ try
+ {
+ socket.close();
+
+ socket = null;
+ }
+ catch (Throwable ignored)
+ {
+ log.warn(ignored.toString(), ignored);
+ }
- socket = null;
-
try
{
thread.interrupt();
@@ -393,7 +400,7 @@
{
received = true;
- waitLock.notify();
+ waitLock.notifyAll();
}
}
}
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/cluster/impl/DiscoveryGroupImpl.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/journal/LoaderCallback.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/journal/impl/JournalReaderCallback.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/persistence/impl/journal/LargeServerMessageImpl.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/persistence/impl/nullpm/NullStorageLargeServerMessage.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Modified:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/ServerSessionPacketHandler.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/ServerSessionPacketHandler.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/ServerSessionPacketHandler.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -79,6 +79,7 @@
import org.hornetq.core.protocol.core.impl.wireformat.SessionSendContinuationMessage;
import org.hornetq.core.protocol.core.impl.wireformat.SessionSendLargeMessage;
import org.hornetq.core.protocol.core.impl.wireformat.SessionSendMessage;
+import org.hornetq.core.protocol.core.impl.wireformat.SessionUniqueAddMetaDataMessage;
import org.hornetq.core.protocol.core.impl.wireformat.SessionXACommitMessage;
import org.hornetq.core.protocol.core.impl.wireformat.SessionXAEndMessage;
import org.hornetq.core.protocol.core.impl.wireformat.SessionXAForgetMessage;
@@ -490,6 +491,23 @@
session.addMetaData(message.getKey(), message.getData());
break;
}
+ case PacketImpl.SESS_UNIQUE_ADD_METADATA:
+ {
+ SessionUniqueAddMetaDataMessage message =
(SessionUniqueAddMetaDataMessage)packet;
+ if (session.addUniqueMetaData(message.getKey(), message.getData()))
+ {
+ response = new NullResponseMessage();
+ }
+ else
+ {
+ response = new HornetQExceptionMessage(new
HornetQException(HornetQException.DUPLICATE_METADATA,
+ "Metadata " +
message.getKey() +
+ "=" +
+ message.getData() +
+ " had been set
already"));
+ }
+ break;
+ }
}
}
catch (HornetQXAException e)
Modified:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/impl/PacketDecoder.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/impl/PacketDecoder.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/impl/PacketDecoder.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -44,6 +44,7 @@
import static org.hornetq.core.protocol.core.impl.PacketImpl.SESS_ACKNOWLEDGE;
import static org.hornetq.core.protocol.core.impl.PacketImpl.SESS_ADD_METADATA;
import static org.hornetq.core.protocol.core.impl.PacketImpl.SESS_ADD_METADATA2;
+import static org.hornetq.core.protocol.core.impl.PacketImpl.SESS_UNIQUE_ADD_METADATA;
import static org.hornetq.core.protocol.core.impl.PacketImpl.SESS_BINDINGQUERY;
import static org.hornetq.core.protocol.core.impl.PacketImpl.SESS_BINDINGQUERY_RESP;
import static org.hornetq.core.protocol.core.impl.PacketImpl.SESS_CLOSE;
@@ -141,6 +142,7 @@
import org.hornetq.core.protocol.core.impl.wireformat.SessionSendContinuationMessage;
import org.hornetq.core.protocol.core.impl.wireformat.SessionSendLargeMessage;
import org.hornetq.core.protocol.core.impl.wireformat.SessionSendMessage;
+import org.hornetq.core.protocol.core.impl.wireformat.SessionUniqueAddMetaDataMessage;
import org.hornetq.core.protocol.core.impl.wireformat.SessionXACommitMessage;
import org.hornetq.core.protocol.core.impl.wireformat.SessionXAEndMessage;
import org.hornetq.core.protocol.core.impl.wireformat.SessionXAForgetMessage;
@@ -538,6 +540,11 @@
packet = new SessionAddMetaDataMessageV2();
break;
}
+ case SESS_UNIQUE_ADD_METADATA:
+ {
+ packet = new SessionUniqueAddMetaDataMessage();
+ break;
+ }
default:
{
throw new IllegalArgumentException("Invalid type: " + packetType);
Modified:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/impl/PacketImpl.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/impl/PacketImpl.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/impl/PacketImpl.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -181,13 +181,17 @@
public static final byte REPLICATION_COMPARE_DATA = 102;
public static final byte REPLICATION_SYNC = 103;
-
- // HA
public static final byte SESS_ADD_METADATA = 104;
public static final byte SESS_ADD_METADATA2 = 105;
+ public static final byte SESS_UNIQUE_ADD_METADATA = 106;
+
+
+
+ // HA
+
public static final byte CLUSTER_TOPOLOGY = 110;
public static final byte NODE_ANNOUNCE = 111;
@@ -200,6 +204,7 @@
public static final byte CLUSTER_TOPOLOGY_V2 = 114;
+
// Static --------------------------------------------------------
public PacketImpl(final byte type)
Modified:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/impl/wireformat/SessionAddMetaDataMessageV2.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/impl/wireformat/SessionAddMetaDataMessageV2.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/impl/wireformat/SessionAddMetaDataMessageV2.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -30,7 +30,7 @@
private String key;
private String data;
/**
- * It won require confirmation during failover / reconnect
+ * It's not required confirmation during failover / reconnect
*/
private boolean requiresConfirmation = true;
@@ -39,6 +39,11 @@
super(PacketImpl.SESS_ADD_METADATA2);
}
+ protected SessionAddMetaDataMessageV2(byte packetCode)
+ {
+ super(packetCode);
+ }
+
public SessionAddMetaDataMessageV2(String k, String d)
{
this();
@@ -46,6 +51,13 @@
data = d;
}
+ protected SessionAddMetaDataMessageV2(final byte packetCode, String k, String d)
+ {
+ super(packetCode);
+ key = k;
+ data = d;
+ }
+
public SessionAddMetaDataMessageV2(String k, String d, boolean requiresConfirmation)
{
this();
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/impl/wireformat/SessionContinuationMessage.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Copied:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/impl/wireformat/SessionUniqueAddMetaDataMessage.java
(from rev 11394,
branches/Branch_2_2_EAP/src/main/org/hornetq/core/protocol/core/impl/wireformat/SessionUniqueAddMetaDataMessage.java)
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/impl/wireformat/SessionUniqueAddMetaDataMessage.java
(rev 0)
+++
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/protocol/core/impl/wireformat/SessionUniqueAddMetaDataMessage.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -0,0 +1,56 @@
+/*
+ * Copyright 2010 Red Hat, Inc.
+ * Red Hat licenses this file to you under the Apache License, version
+ * 2.0 (the "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
http://www.apache.org/licenses/LICENSE-2.0
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+ * implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+package org.hornetq.core.protocol.core.impl.wireformat;
+
+
+/**
+ * A SessionUniqueAddMetaDataMessageV2
+ *
+ * @author clebertsuconic
+ *
+ *
+ */
+public class SessionUniqueAddMetaDataMessage extends SessionAddMetaDataMessageV2
+{
+
+ // Constants -----------------------------------------------------
+
+ // Attributes ----------------------------------------------------
+
+ // Static --------------------------------------------------------
+
+ // Constructors --------------------------------------------------
+
+ public SessionUniqueAddMetaDataMessage()
+ {
+ super(SESS_UNIQUE_ADD_METADATA);
+ }
+
+
+ public SessionUniqueAddMetaDataMessage(String key, String data)
+ {
+ super(SESS_UNIQUE_ADD_METADATA, key, data);
+ }
+
+ // Public --------------------------------------------------------
+
+ // Package protected ---------------------------------------------
+
+ // Protected -----------------------------------------------------
+
+ // Private -------------------------------------------------------
+
+ // Inner classes -------------------------------------------------
+
+}
Modified:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/remoting/server/impl/RemotingServiceImpl.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/remoting/server/impl/RemotingServiceImpl.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/remoting/server/impl/RemotingServiceImpl.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -65,7 +65,7 @@
// Constants -----------------------------------------------------
private static final Logger log = Logger.getLogger(RemotingServiceImpl.class);
-
+
private static final boolean isTrace = log.isTraceEnabled();
public static final long CONNECTION_TTL_CHECK_INTERVAL = 2000;
@@ -95,7 +95,7 @@
private final ScheduledExecutorService scheduledThreadPool;
private FailureCheckAndFlushThread failureCheckAndFlushThread;
-
+
private final ClusterManager clusterManager;
private Map<ProtocolType, ProtocolManager> protocolMap = new
ConcurrentHashMap<ProtocolType, ProtocolManager>();
@@ -113,7 +113,7 @@
transportConfigs = config.getAcceptorConfigurations();
this.server = server;
-
+
this.clusterManager = clusterManager;
ClassLoader loader = Thread.currentThread().getContextClassLoader();
@@ -136,13 +136,13 @@
this.scheduledThreadPool = scheduledThreadPool;
- this.protocolMap.put(ProtocolType.CORE, new
CoreProtocolManagerFactory().createProtocolManager(server,
-
interceptors));
+ this.protocolMap.put(ProtocolType.CORE,
+ new CoreProtocolManagerFactory().createProtocolManager(server,
interceptors));
// difference between Stomp and Stomp over Web Sockets is handled in
NettyAcceptor.getPipeline()
- this.protocolMap.put(ProtocolType.STOMP, new
StompProtocolManagerFactory().createProtocolManager(server,
-
interceptors));
- this.protocolMap.put(ProtocolType.STOMP_WS, new
StompProtocolManagerFactory().createProtocolManager(server,
-
interceptors));
+ this.protocolMap.put(ProtocolType.STOMP,
+ new
StompProtocolManagerFactory().createProtocolManager(server, interceptors));
+ this.protocolMap.put(ProtocolType.STOMP_WS,
+ new
StompProtocolManagerFactory().createProtocolManager(server, interceptors));
}
// RemotingService implementation -------------------------------
@@ -168,9 +168,9 @@
// This needs to be a different thread pool to the main thread pool especially for
OIO where we may need
// to support many hundreds of connections, but the main thread pool must be kept
small for better performance
- ThreadFactory tFactory = new
HornetQThreadFactory("HornetQ-remoting-threads-" + server.toString() +
"-" + System.identityHashCode(this),
- false,
- tccl);
+ ThreadFactory tFactory = new
HornetQThreadFactory("HornetQ-remoting-threads-" + server.toString() +
+ "-" +
+ System.identityHashCode(this),
false, tccl);
threadPool = Executors.newCachedThreadPool(tFactory);
@@ -275,7 +275,6 @@
}
failureCheckAndFlushThread.close();
-
// We need to stop them accepting first so no new connections are accepted after we
send the disconnect message
for (Acceptor acceptor : acceptors)
@@ -297,7 +296,7 @@
for (ConnectionEntry entry : connections.values())
{
RemotingConnection conn = entry.connection;
-
+
if (log.isTraceEnabled())
{
log.trace("Sending connection.disconnection packet to " + conn);
@@ -398,23 +397,23 @@
{
log.trace("Connection created " + connection);
}
-
+
connections.put(connection.getID(), entry);
if (config.isBackup())
{
serverSideReplicatingConnection = entry.connection;
- }
+ }
}
-
+
public void connectionDestroyed(final Object connectionID)
{
- if (isTrace)
- {
- log.trace("Connection removed " + connectionID + " from server
" + this.server, new Exception ("trace"));
- }
-
+ if (isTrace)
+ {
+ log.trace("Connection removed " + connectionID + " from server
" + this.server, new Exception("trace"));
+ }
+
ConnectionEntry conn = connections.get(connectionID);
if (conn != null)
@@ -459,7 +458,7 @@
// Connections should only fail when TTL is exceeded
}
-
+
public void connectionReadyForWrites(final Object connectionID, final boolean ready)
{
}
@@ -496,10 +495,10 @@
}
else
{
- if (log.isTraceEnabled())
- {
- log.trace("ConnectionID = " + connectionID + " was already
closed, so ignoring packet");
- }
+ if (log.isTraceEnabled())
+ {
+ log.trace("ConnectionID = " + connectionID + " was already
closed, so ignoring packet");
+ }
}
}
}
@@ -540,76 +539,85 @@
{
while (!closed)
{
- long now = System.currentTimeMillis();
+ try
+ {
+ long now = System.currentTimeMillis();
- Set<Object> idsToRemove = new HashSet<Object>();
+ Set<Object> idsToRemove = new HashSet<Object>();
- for (ConnectionEntry entry : connections.values())
- {
- RemotingConnection conn = entry.connection;
+ for (ConnectionEntry entry : connections.values())
+ {
+ RemotingConnection conn = entry.connection;
- boolean flush = true;
+ boolean flush = true;
- if (entry.ttl != -1)
- {
- if (now >= entry.lastCheck + entry.ttl)
+ if (entry.ttl != -1)
{
- if (!conn.checkDataReceived())
+ if (now >= entry.lastCheck + entry.ttl)
{
- idsToRemove.add(conn.getID());
+ if (!conn.checkDataReceived())
+ {
+ idsToRemove.add(conn.getID());
- flush = false;
+ flush = false;
+ }
+ else
+ {
+ entry.lastCheck = now;
+ }
}
- else
- {
- entry.lastCheck = now;
- }
}
+
+ if (flush)
+ {
+ conn.flush();
+ }
}
- if (flush)
+ for (Object id : idsToRemove)
{
- conn.flush();
+ RemotingConnection conn = removeConnection(id);
+ if (conn != null)
+ {
+ HornetQException me = new
HornetQException(HornetQException.CONNECTION_TIMEDOUT,
+ "Did not receive
data from " + conn.getRemoteAddress() +
+ ". It is
likely the client has exited or crashed without " +
+ "closing
its connection, or the network between the server and client has failed. " +
+ "You also
might have configured connection-ttl and client-failure-check-period incorrectly. "
+
+ "Please
check user manual for more information." +
+ " The
connection will now be closed.");
+ conn.fail(me);
+ }
}
- }
- for (Object id : idsToRemove)
- {
- RemotingConnection conn = removeConnection(id);
+ synchronized (this)
+ {
+ long toWait = pauseInterval;
- HornetQException me = new
HornetQException(HornetQException.CONNECTION_TIMEDOUT,
- "Did not receive data from
" + conn.getRemoteAddress() +
- ". It is likely
the client has exited or crashed without " +
- "closing its
connection, or the network between the server and client has failed. " +
- "You also might
have configured connection-ttl and client-failure-check-period incorrectly. " +
- "Please check
user manual for more information." +
- " The connection
will now be closed.");
- conn.fail(me);
- }
+ long start = System.currentTimeMillis();
- synchronized (this)
- {
- long toWait = pauseInterval;
-
- long start = System.currentTimeMillis();
-
- while (!closed && toWait > 0)
- {
- try
+ while (!closed && toWait > 0)
{
- wait(toWait);
- }
- catch (InterruptedException e)
- {
- }
+ try
+ {
+ wait(toWait);
+ }
+ catch (InterruptedException e)
+ {
+ }
- now = System.currentTimeMillis();
+ now = System.currentTimeMillis();
- toWait -= now - start;
+ toWait -= now - start;
- start = now;
+ start = now;
+ }
}
}
+ catch (Throwable e)
+ {
+ log.warn(e.getMessage(), e);
+ }
}
}
}
Modified:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/server/HornetQServer.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/server/HornetQServer.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/server/HornetQServer.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -132,6 +132,9 @@
List<ServerSession> getSessions(String connectionID);
+ /** will return true if there is any session wth this key */
+ boolean lookupSession(String metakey, String metavalue);
+
ClusterManager getClusterManager();
SimpleString getNodeID();
Modified:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/server/ServerSession.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/server/ServerSession.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/server/ServerSession.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -121,6 +121,8 @@
void addMetaData(String key, String data);
+ boolean addUniqueMetaData(String key, String data);
+
String getMetaData(String key);
String[] getTargetAddresses();
Modified:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/server/impl/HornetQServerImpl.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/server/impl/HornetQServerImpl.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/server/impl/HornetQServerImpl.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -797,6 +797,23 @@
sessions.remove(name);
}
+ public boolean lookupSession(String key, String value)
+ {
+ // getSessions is called here in a try to minimize locking the Server while this
check is being done
+ Set<ServerSession> allSessions = getSessions();
+
+ for (ServerSession session : allSessions)
+ {
+ String metaValue = session.getMetaData(key);
+ if (metaValue != null && metaValue.equals(value))
+ {
+ return true;
+ }
+ }
+
+ return false;
+ }
+
public synchronized List<ServerSession> getSessions(final String connectionID)
{
Set<Entry<String, ServerSession>> sessionEntries =
sessions.entrySet();
Modified:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/server/impl/ServerSessionImpl.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/server/impl/ServerSessionImpl.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/server/impl/ServerSessionImpl.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -1194,6 +1194,21 @@
metaData.put(key, data);
}
+
+ public boolean addUniqueMetaData(String key, String data)
+ {
+ if (server.lookupSession(key, data))
+ {
+ // There is a duplication of this property
+ return false;
+ }
+ else
+ {
+ addMetaData(key, data);
+ return true;
+ }
+ }
+
public String getMetaData(String key)
{
String data = null;
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/server/management/ManagementService.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/core/server/management/impl/ManagementServiceImpl.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Modified:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/jms/client/HornetQConnection.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/jms/client/HornetQConnection.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/jms/client/HornetQConnection.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -181,6 +181,18 @@
{
throw new IllegalStateException("setClientID can only be called directly
after the connection is created");
}
+
+ try
+ {
+ initialSession.addUniqueMetaData("jms-client-id", clientID);
+ }
+ catch (HornetQException e)
+ {
+ if (e.getCode() == HornetQException.DUPLICATE_METADATA)
+ {
+ throw new IllegalStateException("clientID=" + clientID + " was
already set into another connection");
+ }
+ }
this.clientID = clientID;
try
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/jms/server/management/JMSManagementService.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/jms/server/management/impl/JMSManagementServiceImpl.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/src/main/org/hornetq/utils/UTF8Util.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/config/ConfigurationTest-defaults.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/jms-tests/config/hornetq-beans.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/jms-tests/config/hornetq-configuration.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/jms-tests/config/hornetq-jms.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/jms-tests/config/hornetq-queues.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/jms-tests/config/hornetq-users.xml
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/jms-tests/config/jndi.properties
___________________________________________________________________
Deleted: svn:mergeinfo
-
Modified:
branches/HORNETQ-316_for_2_2_EAP/tests/jms-tests/src/org/hornetq/jms/tests/ConnectionTest.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/tests/jms-tests/src/org/hornetq/jms/tests/ConnectionTest.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/tests/jms-tests/src/org/hornetq/jms/tests/ConnectionTest.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -88,8 +88,21 @@
connection.setClientID(clientID);
ProxyAssertSupport.assertEquals(clientID, connection.getClientID());
+
+ Connection connection2 = JMSTest.cf.createConnection();
+ try
+ {
+ connection2.setClientID(clientID);
+ fail("setClientID was expected to throw an exception");
+ }
+ catch (JMSException e)
+ {
+ // expected
+ }
connection.close();
+
+ connection2.setClientID(clientID);
}
public void testSetClientAfterStart() throws Exception
Modified:
branches/HORNETQ-316_for_2_2_EAP/tests/jms-tests/src/org/hornetq/jms/tests/message/MessageHeaderTest.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/tests/jms-tests/src/org/hornetq/jms/tests/message/MessageHeaderTest.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/tests/jms-tests/src/org/hornetq/jms/tests/message/MessageHeaderTest.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -1417,6 +1417,15 @@
// TODO Auto-generated method stub
}
+
+ /* (non-Javadoc)
+ * @see
org.hornetq.api.core.client.ClientSession#addUniqueMetaData(java.lang.String,
java.lang.String)
+ */
+ public void addUniqueMetaData(String key, String data) throws HornetQException
+ {
+ // TODO Auto-generated method stub
+
+ }
}
}
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/AckBatchSizeTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/AcknowledgeTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/AutogroupIdTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/CommitRollbackTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/ConsumerCloseTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/ConsumerRoundRobinTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/ConsumerTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/ConsumerWindowSizeTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/DeliveryOrderTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/LargeMessageTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/MessageCounterTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/MessageHandlerTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/MessageRateTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/PagingTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/ProducerCloseTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/QueueBrowserTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/ReceiveTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/RequestorTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/RoutingTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/SessionCloseTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/SessionCreateAndDeleteQueueTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/SessionCreateConsumerTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/SessionCreateProducerTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/SessionFactoryTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/SessionSendAcknowledgementHandlerTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/SessionStopStartTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/SessionTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/client/TransactionalSendTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Modified:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/cluster/distribution/ClusterTestBase.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/cluster/distribution/ClusterTestBase.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/cluster/distribution/ClusterTestBase.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -106,7 +106,7 @@
}
- private static final long TIMEOUT_START_SERVER = 10;
+ private static final long TIMEOUT_START_SERVER = 400;
@Override
protected void setUp() throws Exception
@@ -1666,8 +1666,8 @@
null,
groupAddress,
port,
- 5000,
- 5000);
+ 1000,
+ 1000);
configuration.getDiscoveryGroupConfigurations().put(dcConfig.getName(), dcConfig);
Modified:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/cluster/topology/TopologyClusterTestBase.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/cluster/topology/TopologyClusterTestBase.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/cluster/topology/TopologyClusterTestBase.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -420,7 +420,7 @@
locator.close();
}
-
+
public void testMultipleClientSessionFactories() throws Throwable
{
startServers(0, 1, 2, 3, 4);
Modified:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/jms/server/management/TopicControlTest.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/jms/server/management/TopicControlTest.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/jms/server/management/TopicControlTest.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -98,7 +98,7 @@
Connection connection_2 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
JMSUtil.createDurableSubscriber(connection_2, topic, clientID, subscriptionName);
Connection connection_3 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
- JMSUtil.createDurableSubscriber(connection_3, topic, clientID, subscriptionName +
"2");
+ JMSUtil.createDurableSubscriber(connection_3, topic, clientID + "2",
subscriptionName + "2");
TopicControl topicControl = createManagementControl();
Assert.assertEquals(3, topicControl.getSubscriptionCount());
@@ -118,7 +118,7 @@
Connection connection_2 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
JMSUtil.createDurableSubscriber(connection_2, topic, clientID, subscriptionName);
Connection connection_3 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
- JMSUtil.createDurableSubscriber(connection_3, topic, clientID, subscriptionName +
"2");
+ JMSUtil.createDurableSubscriber(connection_3, topic, clientID+"_2",
subscriptionName + "2");
TopicControl topicControl = createManagementControl();
@@ -145,7 +145,7 @@
Connection connection_2 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
TopicSubscriber subs1 = JMSUtil.createDurableSubscriber(connection_2, topic,
clientID, subscriptionName);
Connection connection_3 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
- TopicSubscriber subs2 = JMSUtil.createDurableSubscriber(connection_3, topic,
clientID, subscriptionName + "2");
+ TopicSubscriber subs2 = JMSUtil.createDurableSubscriber(connection_3, topic,
clientID + "2", subscriptionName + "2");
TopicControl topicControl = createManagementControl();
Assert.assertEquals(3, topicControl.listAllSubscriptions().length);
@@ -171,7 +171,7 @@
Connection connection_2 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
JMSUtil.createDurableSubscriber(connection_2, topic, clientID, subscriptionName);
Connection connection_3 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
- JMSUtil.createDurableSubscriber(connection_3, topic, clientID, subscriptionName +
"2");
+ JMSUtil.createDurableSubscriber(connection_3, topic, clientID+"2",
subscriptionName + "2");
TopicControl topicControl = createManagementControl();
String jsonString = topicControl.listDurableSubscriptionsAsJSON();
@@ -179,7 +179,7 @@
Assert.assertEquals(2, infos.length);
Assert.assertEquals(clientID, infos[0].getClientID());
Assert.assertEquals(subscriptionName, infos[0].getName());
- Assert.assertEquals(clientID, infos[1].getClientID());
+ Assert.assertEquals(clientID+"2", infos[1].getClientID());
Assert.assertEquals(subscriptionName + "2", infos[1].getName());
jsonString = topicControl.listNonDurableSubscriptionsAsJSON();
@@ -344,7 +344,7 @@
Connection connection_1 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
JMSUtil.createDurableSubscriber(connection_1, topic, clientID, subscriptionName);
Connection connection_2 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
- JMSUtil.createDurableSubscriber(connection_2, topic, clientID, subscriptionName +
"2");
+ JMSUtil.createDurableSubscriber(connection_2, topic, clientID+"2",
subscriptionName + "2");
JMSUtil.sendMessages(topic, 3);
@@ -438,7 +438,7 @@
Connection connection_2 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
JMSUtil.createDurableSubscriber(connection_2, topic, clientID, subscriptionName);
Connection connection_3 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
- JMSUtil.createDurableSubscriber(connection_3, topic, clientID, subscriptionName +
"2");
+ JMSUtil.createDurableSubscriber(connection_3, topic, clientID+"2",
subscriptionName + "2");
TopicControl topicControl = createManagementControl();
@@ -460,7 +460,7 @@
Connection connection_2 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
MessageConsumer cons_2 = JMSUtil.createDurableSubscriber(connection_2, topic,
clientID, subscriptionName, Session.CLIENT_ACKNOWLEDGE);
Connection connection_3 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
- MessageConsumer cons_3 = JMSUtil.createDurableSubscriber(connection_3, topic,
clientID, subscriptionName + "2", Session.CLIENT_ACKNOWLEDGE);
+ MessageConsumer cons_3 = JMSUtil.createDurableSubscriber(connection_3, topic,
clientID+"2", subscriptionName + "2", Session.CLIENT_ACKNOWLEDGE);
TopicControl topicControl = createManagementControl();
Modified:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/jms/server/management/TopicControlUsingJMSTest.java
===================================================================
---
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/jms/server/management/TopicControlUsingJMSTest.java 2011-09-21
19:59:57 UTC (rev 11394)
+++
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/jms/server/management/TopicControlUsingJMSTest.java 2011-09-22
01:37:18 UTC (rev 11395)
@@ -13,7 +13,6 @@
package org.hornetq.tests.integration.jms.server.management;
-import static junit.framework.Assert.assertEquals;
import static org.hornetq.tests.util.RandomUtil.randomString;
import javax.jms.Connection;
@@ -30,9 +29,7 @@
import org.hornetq.api.core.management.ResourceNames;
import org.hornetq.api.jms.HornetQJMSClient;
import org.hornetq.api.jms.JMSFactoryType;
-import org.hornetq.api.jms.management.TopicControl;
import org.hornetq.core.config.Configuration;
-import org.hornetq.core.config.impl.ConfigurationImpl;
import org.hornetq.core.remoting.impl.invm.InVMConnectorFactory;
import org.hornetq.core.server.HornetQServer;
import org.hornetq.core.server.HornetQServers;
@@ -96,7 +93,7 @@
Connection connection_2 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
JMSUtil.createDurableSubscriber(connection_2, topic, clientID, subscriptionName);
Connection connection_3 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
- JMSUtil.createDurableSubscriber(connection_3, topic, clientID, subscriptionName +
"2");
+ JMSUtil.createDurableSubscriber(connection_3, topic, clientID + "2",
subscriptionName + "2");
Assert.assertEquals(3,
proxy.retrieveAttributeValue("subscriptionCount"));
Assert.assertEquals(1,
proxy.retrieveAttributeValue("nonDurableSubscriptionCount"));
@@ -115,7 +112,7 @@
Connection connection_2 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
JMSUtil.createDurableSubscriber(connection_2, topic, clientID, subscriptionName);
Connection connection_3 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
- JMSUtil.createDurableSubscriber(connection_3, topic, clientID, subscriptionName +
"2");
+ JMSUtil.createDurableSubscriber(connection_3, topic, clientID + "2",
subscriptionName + "2");
Assert.assertEquals(0, proxy.retrieveAttributeValue("messageCount"));
Assert.assertEquals(0,
proxy.retrieveAttributeValue("nonDurableMessageCount"));
@@ -140,7 +137,7 @@
Connection connection_2 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
JMSUtil.createDurableSubscriber(connection_2, topic, clientID, subscriptionName);
Connection connection_3 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
- JMSUtil.createDurableSubscriber(connection_3, topic, clientID, subscriptionName +
"2");
+ JMSUtil.createDurableSubscriber(connection_3, topic, clientID + "2",
subscriptionName + "2");
Assert.assertEquals(3,
((Object[])proxy.invokeOperation("listAllSubscriptions")).length);
Assert.assertEquals(1,
((Object[])proxy.invokeOperation("listNonDurableSubscriptions")).length);
@@ -254,7 +251,7 @@
Connection connection_2 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
TopicSubscriber durableSubscriber_2 =
JMSUtil.createDurableSubscriber(connection_2,
topic,
- clientID,
+ clientID +
"2",
subscriptionName + "2");
Assert.assertEquals(2,
proxy.retrieveAttributeValue("subscriptionCount"));
@@ -276,7 +273,7 @@
Connection connection_1 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
JMSUtil.createDurableSubscriber(connection_1, topic, clientID, subscriptionName);
Connection connection_2 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
- JMSUtil.createDurableSubscriber(connection_2, topic, clientID, subscriptionName +
"2");
+ JMSUtil.createDurableSubscriber(connection_2, topic, clientID + "2",
subscriptionName + "2");
JMSUtil.sendMessages(topic, 3);
@@ -344,7 +341,7 @@
Connection connection_2 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
JMSUtil.createDurableSubscriber(connection_2, topic, clientID, subscriptionName);
Connection connection_3 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
- JMSUtil.createDurableSubscriber(connection_3, topic, clientID, subscriptionName +
"2");
+ JMSUtil.createDurableSubscriber(connection_3, topic, clientID + "2",
subscriptionName + "2");
assertEquals(0, proxy.retrieveAttributeValue("messagesAdded"));
@@ -370,7 +367,7 @@
Connection connection_3 =
JMSUtil.createConnection(InVMConnectorFactory.class.getName());
MessageConsumer cons_3 = JMSUtil.createDurableSubscriber(connection_3,
topic,
- clientID,
+ clientID + "2",
subscriptionName +
"2",
Session.CLIENT_ACKNOWLEDGE);
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/journal/NIOJournalCompactTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/integration/management/SecurityManagementTestBase.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/stress/paging/PageStressTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/unit/core/asyncio/AsynchronousFileTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/unit/core/asyncio/MultiThreadAsynchronousFileTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/unit/core/config/impl/DefaultsFileConfigurationTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-
Property changes on:
branches/HORNETQ-316_for_2_2_EAP/tests/src/org/hornetq/tests/unit/core/paging/impl/PagingManagerImplTest.java
___________________________________________________________________
Deleted: svn:mergeinfo
-