Issue
This Content is from Stack Overflow. Question asked by barе37
i have an app to send and receive messages(simplified)
<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:cm="http://aries.apache.org/blueprint/xmlns/blueprint-cm/v1.1.0"
xmlns:cxf="http://cxf.apache.org/blueprint/core"
xmlns:camelcxf="http://camel.apache.org/schema/blueprint/cxf"
xmlns:bas="http://www.1c-esb.ru/basic-auth-service/"
xmlns:jpa="http://aries.apache.org/xmlns/jpa/v2.0.0"
xmlns:tx="http://aries.apache.org/xmlns/transactions/v1.2.0"
xsi:schemaLocation="
http://www.osgi.org/xmlns/blueprint/v1.0.0 https://www.osgi.org/xmlns/blueprint/v1.0.0/blueprint.xsd
http://cxf.apache.org/blueprint/core http://cxf.apache.org/schemas/blueprint/core.xsd
">
<bean id="artemisConnectionFactory" class="org.apache.activemq.artemis.jms.client.ActiveMQJMSConnectionFactory">
<argument index="0" value="${ru.1c.esb.jms.url}"/>
<argument index="1" value="${ru.1c.esb.jms.username}"/>
<argument index="2" value="${ru.1c.esb.jms.password}"/>
</bean>
<bean id="pooledConnectionFactory" class="org.messaginghub.pooled.jms.JmsPoolConnectionFactory"
init-method="start" destroy-method="stop">
<property name="maxConnections" value="10"/>
<property name="maxSessionsPerConnection" value="500"/>
<property name="connectionFactory" ref="artemisConnectionFactory"/>
</bean>
<bean id="jms" class="org.apache.camel.component.jms.JmsComponent">
<property name="connectionFactory" ref="pooledConnectionFactory"/>
</bean>
<camelContext xmlns="http://camel.apache.org/schema/blueprint">
<route>
<from uri="jetty:http://0.0.0.0:8089/put-message"/>
<inOnly uri="jms:my-queue"/>
</route>
<route >
<from uri="jetty:http://0.0.0.0:8089/get-message"/>
<pollEnrich timeout="10">
<simple>jms:queue:my-queue</simple>
</pollEnrich>
</route>
</camelContext>
stack:
activemq artemis 2.25
camel 2.23.2
karaf 4.2
messaginghub/pooled-jms 1.0.6
artemis-jms-client-osgi 2.7.0
I am doing load testing (Apache Bench 5kb messages, 100 threads for sending and 100 threads for receiving) and I observe the following picture:
the service works for half an hour without problems(queue does not increase in size), but then the time for receiving messages from the queue increases, I was able to reduce some metrics and noticed that it increases oldGen(at the same time, the queue has not yet left in the PAGE mode)
XX:+UseParallelOldGC was used when starting Artemis
you can see how the time to receive messages from the queue increases
What could be the reason for the increase memory oldgen?
What other metrics can I apply to deal with the problem?
Solution
This question is not yet answered, be the first one who answer using the comment. Later the confirmed answer will be published as the solution.
This Question and Answer are collected from stackoverflow and tested by JTuto community, is licensed under the terms of CC BY-SA 2.5. - CC BY-SA 3.0. - CC BY-SA 4.0.