You are viewing a plain text version of this content. The canonical link for it is here.
Posted to server-dev@james.apache.org by "ouvtam (Jira)" <se...@james.apache.org> on 2022/11/02 23:19:00 UTC

[jira] [Created] (JAMES-3848) ActiveMQ dequeuing can block (infinite timeout)

ouvtam created JAMES-3848:
-----------------------------

             Summary: ActiveMQ dequeuing can block (infinite timeout)
                 Key: JAMES-3848
                 URL: https://issues.apache.org/jira/browse/JAMES-3848
             Project: James Server
          Issue Type: Improvement
          Components: Queue
            Reporter: ouvtam


While working on JAMES-3841 I stumbled blocking code that might be investigated.

When calling ActiveMQMessageConsumer#receive(timeout) it blocks until a new message is received when prefetchSize is zero (seeĀ org.apache.activemq.ActiveMQMessageConsumer#receive) even when a timeout is given. That would explain some observed timeouts in disabled tests in the test package org.apache.james.queue.activemq.

One way to mitigate this is to set prefetch size greater than zero to make the timeout occur. But this would also mean that code that relies on blocking dequeues must be rewritten.

What do you think?



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: server-dev-unsubscribe@james.apache.org
For additional commands, e-mail: server-dev-help@james.apache.org