You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@camel.apache.org by "Qingyi Gu (JIRA)" <ji...@apache.org> on 2010/05/19 20:23:13 UTC
[jira] Created: (CAMEL-2740) Using static queue as a reply queue in
InOut pattern causes memory leak
Using static queue as a reply queue in InOut pattern causes memory leak
-----------------------------------------------------------------------
Key: CAMEL-2740
URL: https://issues.apache.org/activemq/browse/CAMEL-2740
Project: Apache Camel
Issue Type: Bug
Components: camel-jms
Affects Versions: 2.2.0
Environment: Windows 2003 server
Reporter: Qingyi Gu
I am running JBoss, ActiveMQ and Camel for my application. In the InOut pattern, I am using a predefined static queue as a reply queue. After running for a while, the memory usage of JBoss keeps growing and growing until it hits outOfMemory error and app server is totally hung. I monitor the thread in jconsole, I can see the jms connection/session keeps growing and growing.
But once I switch to use temp queue for InOut pattern, this problem goes away.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (CAMEL-2740) Using static queue as a reply queue
in InOut pattern causes memory leak
Posted by "Qingyi Gu (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/activemq/browse/CAMEL-2740?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=59516#action_59516 ]
Qingyi Gu commented on CAMEL-2740:
----------------------------------
Here are some more details.
AMQ: I have two activemq and there is one network connector between them. See config below.
<networkConnector name="server1" uri="static://(https://localhost:61617?proxyHost=server1&proxyPort=80)" duplex="true">
<!-- limit store and forward to specific queues -->
<dynamicallyIncludedDestinations>
<queue physicalName="TO_SERVER1.>"/>
<queue physicalName="TO_SCA.>"/>
</dynamicallyIncludedDestinations>
<staticallyIncludedDestinations>
<queue physicalName="TO_SERVER1.SYNC_RESP"/>
<queue physicalName="TO_SCA.SSO.SYNC_REQ"/>
</staticallyIncludedDestinations>
</networkConnector>
Camel Route on consumer side:
from("jms:queue:TO_SCA.SSO.SYNC_REQ?concurrentConsumers=25")
.choice()
.when(header(JMS_HEADER_TYPE).isEqualTo("TYPE1"))
.beanRef("service1")
.when(header(JMS_HEADER_TYPE).isEqualTo("TYPE2"))
.beanRef("service2")
.otherwise()
.beanRef("unknownService")
.end();
On producer side:
HashMap<String, Object> reqHeaders = new HashMap<String, Object>();
reqHeaders.put("JMSType", "TYPE1");
// Options
StringBuffer options = new StringBuffer();
options.append("?");
options.append("replyTo");
options.append("=");
options.append("TO_EC.SERVER1.SYNC_RESP");
// Send Message
String outMsg = (String)camelTemplate.sendBodyAndHeaders("jms:queue:TO_SCA.SSO.SYNC_REQ"+options.toString(),
ExchangePattern.InOut,
inMsg,
reqHeaders);
> Using static queue as a reply queue in InOut pattern causes memory leak
> -----------------------------------------------------------------------
>
> Key: CAMEL-2740
> URL: https://issues.apache.org/activemq/browse/CAMEL-2740
> Project: Apache Camel
> Issue Type: Bug
> Components: camel-jms
> Affects Versions: 2.2.0
> Environment: Windows 2003 server
> Reporter: Qingyi Gu
>
> I am running JBoss, ActiveMQ and Camel for my application. In the InOut pattern, I am using a predefined static queue as a reply queue. After running for a while, the memory usage of JBoss keeps growing and growing until it hits outOfMemory error and app server is totally hung. I monitor the thread in jconsole, I can see the jms connection/session keeps growing and growing.
> But once I switch to use temp queue for InOut pattern, this problem goes away.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (CAMEL-2740) Using static queue as a reply queue
in InOut pattern causes memory leak
Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/activemq/browse/CAMEL-2740?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=59574#action_59574 ]
Claus Ibsen commented on CAMEL-2740:
------------------------------------
Can you crete a small project and attach a zip file with it? Then its easier to use to look into this.
> Using static queue as a reply queue in InOut pattern causes memory leak
> -----------------------------------------------------------------------
>
> Key: CAMEL-2740
> URL: https://issues.apache.org/activemq/browse/CAMEL-2740
> Project: Apache Camel
> Issue Type: Bug
> Components: camel-jms
> Affects Versions: 2.2.0
> Environment: Windows 2003 server
> Reporter: Qingyi Gu
>
> I am running JBoss, ActiveMQ and Camel for my application. In the InOut pattern, I am using a predefined static queue as a reply queue. After running for a while, the memory usage of JBoss keeps growing and growing until it hits outOfMemory error and app server is totally hung. I monitor the thread in jconsole, I can see the jms connection/session keeps growing and growing.
> But once I switch to use temp queue for InOut pattern, this problem goes away.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (CAMEL-2740) Using static queue as a reply queue
in InOut pattern causes memory leak
Posted by "Qingyi Gu (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/activemq/browse/CAMEL-2740?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=59515#action_59515 ]
Qingyi Gu commented on CAMEL-2740:
----------------------------------
Here is the version of software.
JBoss 4.2.2
AMQ 5.3.1
JDK 1.5.0_22
Camel 2.2.0
> Using static queue as a reply queue in InOut pattern causes memory leak
> -----------------------------------------------------------------------
>
> Key: CAMEL-2740
> URL: https://issues.apache.org/activemq/browse/CAMEL-2740
> Project: Apache Camel
> Issue Type: Bug
> Components: camel-jms
> Affects Versions: 2.2.0
> Environment: Windows 2003 server
> Reporter: Qingyi Gu
>
> I am running JBoss, ActiveMQ and Camel for my application. In the InOut pattern, I am using a predefined static queue as a reply queue. After running for a while, the memory usage of JBoss keeps growing and growing until it hits outOfMemory error and app server is totally hung. I monitor the thread in jconsole, I can see the jms connection/session keeps growing and growing.
> But once I switch to use temp queue for InOut pattern, this problem goes away.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (CAMEL-2740) Using static queue as a reply queue
in InOut pattern causes memory leak
Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/activemq/browse/CAMEL-2740?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=59511#action_59511 ]
Claus Ibsen commented on CAMEL-2740:
------------------------------------
Could you post more details, eg what Camel route do you use?
And how have you setup ActiveMQ?
> Using static queue as a reply queue in InOut pattern causes memory leak
> -----------------------------------------------------------------------
>
> Key: CAMEL-2740
> URL: https://issues.apache.org/activemq/browse/CAMEL-2740
> Project: Apache Camel
> Issue Type: Bug
> Components: camel-jms
> Affects Versions: 2.2.0
> Environment: Windows 2003 server
> Reporter: Qingyi Gu
>
> I am running JBoss, ActiveMQ and Camel for my application. In the InOut pattern, I am using a predefined static queue as a reply queue. After running for a while, the memory usage of JBoss keeps growing and growing until it hits outOfMemory error and app server is totally hung. I monitor the thread in jconsole, I can see the jms connection/session keeps growing and growing.
> But once I switch to use temp queue for InOut pattern, this problem goes away.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (CAMEL-2740) Using static queue as a reply queue
in InOut pattern causes memory leak
Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/activemq/browse/CAMEL-2740?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Claus Ibsen resolved CAMEL-2740.
--------------------------------
Fix Version/s: 2.5.0
Resolution: Incomplete
User doesn't respond
> Using static queue as a reply queue in InOut pattern causes memory leak
> -----------------------------------------------------------------------
>
> Key: CAMEL-2740
> URL: https://issues.apache.org/activemq/browse/CAMEL-2740
> Project: Apache Camel
> Issue Type: Bug
> Components: camel-jms
> Affects Versions: 2.2.0
> Environment: Windows 2003 server
> Reporter: Qingyi Gu
> Fix For: 2.5.0
>
>
> I am running JBoss, ActiveMQ and Camel for my application. In the InOut pattern, I am using a predefined static queue as a reply queue. After running for a while, the memory usage of JBoss keeps growing and growing until it hits outOfMemory error and app server is totally hung. I monitor the thread in jconsole, I can see the jms connection/session keeps growing and growing.
> But once I switch to use temp queue for InOut pattern, this problem goes away.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (CAMEL-2740) Using static queue as a reply queue
in InOut pattern causes memory leak
Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/activemq/browse/CAMEL-2740?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=60895#action_60895 ]
Claus Ibsen commented on CAMEL-2740:
------------------------------------
See this FAQ about the correct way of using templates
http://camel.apache.org/why-does-camel-use-too-many-threads-with-producertemplate.html
And also try Camel 2.5 because the request-reply logic over JMS have been refactored a bit to cater for async routing engine.
> Using static queue as a reply queue in InOut pattern causes memory leak
> -----------------------------------------------------------------------
>
> Key: CAMEL-2740
> URL: https://issues.apache.org/activemq/browse/CAMEL-2740
> Project: Apache Camel
> Issue Type: Bug
> Components: camel-jms
> Affects Versions: 2.2.0
> Environment: Windows 2003 server
> Reporter: Qingyi Gu
>
> I am running JBoss, ActiveMQ and Camel for my application. In the InOut pattern, I am using a predefined static queue as a reply queue. After running for a while, the memory usage of JBoss keeps growing and growing until it hits outOfMemory error and app server is totally hung. I monitor the thread in jconsole, I can see the jms connection/session keeps growing and growing.
> But once I switch to use temp queue for InOut pattern, this problem goes away.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (CAMEL-2740) Using static queue as a reply queue
in InOut pattern causes memory leak
Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/activemq/browse/CAMEL-2740?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=59512#action_59512 ]
Claus Ibsen commented on CAMEL-2740:
------------------------------------
And what versions of the various software are you using? eg JBoss, AMQ, JDK etc.
> Using static queue as a reply queue in InOut pattern causes memory leak
> -----------------------------------------------------------------------
>
> Key: CAMEL-2740
> URL: https://issues.apache.org/activemq/browse/CAMEL-2740
> Project: Apache Camel
> Issue Type: Bug
> Components: camel-jms
> Affects Versions: 2.2.0
> Environment: Windows 2003 server
> Reporter: Qingyi Gu
>
> I am running JBoss, ActiveMQ and Camel for my application. In the InOut pattern, I am using a predefined static queue as a reply queue. After running for a while, the memory usage of JBoss keeps growing and growing until it hits outOfMemory error and app server is totally hung. I monitor the thread in jconsole, I can see the jms connection/session keeps growing and growing.
> But once I switch to use temp queue for InOut pattern, this problem goes away.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.