[
https://issues.apache.org/jira/browse/ARTEMIS-5093?focusedWorklogId=938584&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-938584
]
ASF GitHub Bot logged work on ARTEMIS-5093:
-------------------------------------------
Author: ASF GitHub Bot
Created on: 17/Oct/24 07:02
Start Date: 17/Oct/24 07:02
Worklog Time Spent: 10m
Work Description: brusdev commented on code in PR #5291:
URL: https://github.com/apache/activemq-artemis/pull/5291#discussion_r1804218190
##########
tests/integration-tests/src/test/java/org/apache/activemq/artemis/tests/integration/client/MessageHandlerTest.java:
##########
@@ -117,6 +118,42 @@ public void onMessage(final ClientMessage message) {
session.close();
}
+ @Test
+ public void testMessageHandlerCloseTimeout() throws Exception {
+ // create Netty acceptor so client can use new onMessageCloseTimeout URL
parameter
+ server.getRemotingService().createAcceptor("netty",
"tcp://127.0.0.1:61616").start();
+ final int timeout = 1000;
Review Comment:
does the test work with a lower timeout to reduce the test duration?
##########
artemis-core-client/src/main/java/org/apache/activemq/artemis/core/client/impl/ClientConsumerImpl.java:
##########
@@ -911,10 +916,10 @@ private void waitForOnMessageToComplete(boolean
waitForOnMessage) {
sessionExecutor.execute(future);
- boolean ok = future.await(ClientConsumerImpl.CLOSE_TIMEOUT_MILLISECONDS);
+ boolean ok = future.await(onMessageCloseTimeout);
Review Comment:
Is the const `CLOSE_TIMEOUT_MILLISECONDS` still required?
Issue Time Tracking
-------------------
Worklog Id: (was: 938584)
Time Spent: 50m (was: 40m)
> Support configurable onMessage timeout when closing consumer
> ------------------------------------------------------------
>
> Key: ARTEMIS-5093
> URL: https://issues.apache.org/jira/browse/ARTEMIS-5093
> Project: ActiveMQ Artemis
> Issue Type: Improvement
> Reporter: Justin Bertram
> Assignee: Justin Bertram
> Priority: Major
> Labels: pull-request-available
> Time Spent: 50m
> Remaining Estimate: 0h
>
> When closing a consumer the Core client is hard-coded to wait for 10,000ms
> for any {{onMessage}} to complete. This timeout should be configurable.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information, visit: https://activemq.apache.org/contact