This is an automated email from the ASF dual-hosted git repository.
clebertsuconic pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/artemis.git
The following commit(s) were added to refs/heads/main by this push:
new 72b581676a ARTEMIS-5915 Small tweak on test
72b581676a is described below
commit 72b581676a8521250cabbf3d951aa8d3ced2d244
Author: Clebert Suconic <[email protected]>
AuthorDate: Fri Feb 27 09:27:28 2026 -0500
ARTEMIS-5915 Small tweak on test
---
.../artemis/tests/integration/DuplicateDetectionTest.java | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git
a/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/DuplicateDetectionTest.java
b/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/DuplicateDetectionTest.java
index b0bf5912ff..291085aa03 100644
---
a/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/DuplicateDetectionTest.java
+++
b/tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/DuplicateDetectionTest.java
@@ -247,16 +247,18 @@ public class DuplicateDetectionTest extends
ActiveMQTestBase {
ClientMessage receivedMessage = consumer.receive(1000);
assertEquals(0, receivedMessage.getObjectProperty(propKey));
+ SimpleString dupID = RandomUtil.randomUUIDSimpleString();
message = createMessage(session, 1);
- SimpleString dupID = SimpleString.of("1q2w3e4r5t6y7u8i9o0p");
message.putBytesProperty(Message.HDR_BRIDGE_DUPLICATE_ID,
dupID.getData());
producer.send(message);
receivedMessage = consumer.receive(1000);
assertEquals(1, receivedMessage.getObjectProperty(propKey));
+ // The second send is setting a new legal duplicateID. The sending
should happen regardless of the IDCacheSize.
+ // However, without the fix provided on ARTEMIS-5915, it would fail.
+ dupID = RandomUtil.randomUUIDSimpleString();
message = createMessage(session, 2);
- SimpleString dupID1 = SimpleString.of("1q2w3e4r5t6y7u8i9o0p");
- message.putBytesProperty(Message.HDR_BRIDGE_DUPLICATE_ID,
dupID1.getData());
+ message.putBytesProperty(Message.HDR_BRIDGE_DUPLICATE_ID,
dupID.getData());
producer.send(message);
receivedMessage = consumer.receive(1000);
assertEquals(2, receivedMessage.getObjectProperty(propKey));
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]