This is an automated email from the ASF dual-hosted git repository.
rcordier pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/james-project.git
The following commit(s) were added to refs/heads/master by this push:
new 56fdbe0b19 JAMES-4200 ActiveMQ: set adjustUsageLimits to false for
BrokerService to prevent the embedded broker to claim up to 70% of JVM memory
that might cause memory drain of James
56fdbe0b19 is described below
commit 56fdbe0b19ac697619e118c67676523600c2ea3a
Author: ouvtam <[email protected]>
AuthorDate: Tue Apr 7 13:59:32 2026 +0200
JAMES-4200 ActiveMQ: set adjustUsageLimits to false for BrokerService to
prevent the embedded broker to claim up to 70% of JVM memory that might cause
memory drain of James
---
.../main/java/org/apache/james/queue/activemq/EmbeddedActiveMQ.java | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git
a/server/queue/queue-activemq/src/main/java/org/apache/james/queue/activemq/EmbeddedActiveMQ.java
b/server/queue/queue-activemq/src/main/java/org/apache/james/queue/activemq/EmbeddedActiveMQ.java
index 75dbad1b0a..afaddfd8dc 100644
---
a/server/queue/queue-activemq/src/main/java/org/apache/james/queue/activemq/EmbeddedActiveMQ.java
+++
b/server/queue/queue-activemq/src/main/java/org/apache/james/queue/activemq/EmbeddedActiveMQ.java
@@ -67,7 +67,9 @@ public class EmbeddedActiveMQ {
@PreDestroy
public void stop() throws Exception {
+ LOGGER.info("Stopping embedded ActiveMQ...");
brokerService.stop();
+ LOGGER.info("Stopped embedded ActiveMQ");
}
private ActiveMQConnectionFactory
createActiveMQConnectionFactory(BlobTransferPolicy blobTransferPolicy) {
@@ -100,6 +102,7 @@ public class EmbeddedActiveMQ {
brokerService.setDataDirectoryFile(fileSystem.getFile(BROCKERS_LOCATION));
brokerService.setUseShutdownHook(false);
brokerService.setSchedulerSupport(false);
+ brokerService.setAdjustUsageLimits(false);
brokerService.setBrokerId(BROKER_ID);
String[] uris = {BROCKER_URI};
brokerService.setTransportConnectorURIs(uris);
@@ -113,6 +116,6 @@ public class EmbeddedActiveMQ {
String[] transportConnectorsURIs = {BROCKER_URI};
brokerService.setTransportConnectorURIs(transportConnectorsURIs);
brokerService.start();
- LOGGER.info("Started embedded activeMq");
+ LOGGER.info("Started embedded ActiveMQ");
}
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]