You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@camel.apache.org by "Eric Levin (JIRA)" <ji...@apache.org> on 2008/06/11 17:00:00 UTC

[jira] Created: (CAMEL-604) New JMS connection being created for every message

New JMS connection being created for every message
--------------------------------------------------

                 Key: CAMEL-604
                 URL: https://issues.apache.org/activemq/browse/CAMEL-604
             Project: Apache Camel
          Issue Type: Bug
          Components: camel-jms
    Affects Versions: 1.3.0
            Reporter: Eric Levin
         Attachments: ActiveMQ-Camel-Test.zip

A new connection is being created / shutdown for every message that is sent through my ActiveMQ JMSComponent.  I thought this issue had been resolved for Camel 1.3; however, as shown within the example project, it doesn't seem to be.  This is very concerning for rapidly produced messages as there is alot of overhead with creating a new connection.

Forum posting on this issue: http://www.nabble.com/New-connection-being-created-for-every-message-(post-1.3-camel)-td17684874s22882.html

Steps to running the attached sample:

-Have an instance of ActiveMQ running (localhost to the test app) with openwire exposed on port 61616 (the default port)
-After extracting the example project, simply run 'mvn test' and it will begin sending messages through Camel
-Open JConsole and look under the Connections for localhost broker - you will notice the suffix on connections increasing very quickly as connections are being opened/torn down for every message sent from the test app.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAMEL-604) New JMS connection being created for every message

Posted by "Hadrian Zbarcea (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/activemq/browse/CAMEL-604?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Hadrian Zbarcea updated CAMEL-604:
----------------------------------

    Fix Version/s: 1.4.0

> New JMS connection being created for every message
> --------------------------------------------------
>
>                 Key: CAMEL-604
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-604
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-jms
>    Affects Versions: 1.3.0
>            Reporter: Eric Levin
>             Fix For: 1.4.0
>
>         Attachments: ActiveMQ-Camel-Test.zip, after 130 messages being sent.jpg, falsealarm.jpg
>
>
> A new connection is being created / shutdown for every message that is sent through my ActiveMQ JMSComponent.  I thought this issue had been resolved for Camel 1.3; however, as shown within the example project, it doesn't seem to be.  This is very concerning for rapidly produced messages as there is alot of overhead with creating a new connection.
> Forum posting on this issue: http://www.nabble.com/New-connection-being-created-for-every-message-(post-1.3-camel)-td17684874s22882.html
> Steps to running the attached sample:
> -Have an instance of ActiveMQ running (localhost to the test app) with openwire exposed on port 61616 (the default port)
> -After extracting the example project, simply run 'mvn test' and it will begin sending messages through Camel
> -Open JConsole and look under the Connections for localhost broker - you will notice the suffix on connections increasing very quickly as connections are being opened/torn down for every message sent from the test app.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAMEL-604) New JMS connection being created for every message

Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/CAMEL-604?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=43497#action_43497 ] 

Claus Ibsen commented on CAMEL-604:
-----------------------------------

And I had to add this to your pom.xml to enable JDK1.5
{code}
  <build>
    <defaultGoal>install</defaultGoal>

    <pluginManagement>
      <plugins>

        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-compiler-plugin</artifactId>
          <version>2.0.2</version>
          <configuration>
            <source>1.5</source>
            <target>1.5</target>
            <maxmem>256M</maxmem>
            <fork>${compiler.fork}</fork>
          </configuration>
        </plugin>

      </plugins>
    </pluginManagement>
{code}

> New JMS connection being created for every message
> --------------------------------------------------
>
>                 Key: CAMEL-604
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-604
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-jms
>    Affects Versions: 1.3.0
>            Reporter: Eric Levin
>         Attachments: ActiveMQ-Camel-Test.zip, after 130 messages being sent.jpg
>
>
> A new connection is being created / shutdown for every message that is sent through my ActiveMQ JMSComponent.  I thought this issue had been resolved for Camel 1.3; however, as shown within the example project, it doesn't seem to be.  This is very concerning for rapidly produced messages as there is alot of overhead with creating a new connection.
> Forum posting on this issue: http://www.nabble.com/New-connection-being-created-for-every-message-(post-1.3-camel)-td17684874s22882.html
> Steps to running the attached sample:
> -Have an instance of ActiveMQ running (localhost to the test app) with openwire exposed on port 61616 (the default port)
> -After extracting the example project, simply run 'mvn test' and it will begin sending messages through Camel
> -Open JConsole and look under the Connections for localhost broker - you will notice the suffix on connections increasing very quickly as connections are being opened/torn down for every message sent from the test app.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAMEL-604) New JMS connection being created for every message

Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/CAMEL-604?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=43502#action_43502 ] 

Claus Ibsen commented on CAMEL-604:
-----------------------------------

I get the same behavior with Camel 1.4-SNAPSHOT as with 1.3.0

> New JMS connection being created for every message
> --------------------------------------------------
>
>                 Key: CAMEL-604
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-604
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-jms
>    Affects Versions: 1.3.0
>            Reporter: Eric Levin
>         Attachments: ActiveMQ-Camel-Test.zip, after 130 messages being sent.jpg
>
>
> A new connection is being created / shutdown for every message that is sent through my ActiveMQ JMSComponent.  I thought this issue had been resolved for Camel 1.3; however, as shown within the example project, it doesn't seem to be.  This is very concerning for rapidly produced messages as there is alot of overhead with creating a new connection.
> Forum posting on this issue: http://www.nabble.com/New-connection-being-created-for-every-message-(post-1.3-camel)-td17684874s22882.html
> Steps to running the attached sample:
> -Have an instance of ActiveMQ running (localhost to the test app) with openwire exposed on port 61616 (the default port)
> -After extracting the example project, simply run 'mvn test' and it will begin sending messages through Camel
> -Open JConsole and look under the Connections for localhost broker - you will notice the suffix on connections increasing very quickly as connections are being opened/torn down for every message sent from the test app.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAMEL-604) New JMS connection being created for every message

Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/CAMEL-604?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=43504#action_43504 ] 

Claus Ibsen commented on CAMEL-604:
-----------------------------------

Eric in the process I tried to use the activemq specifc component in Camel
http://activemq.apache.org/camel/activemq.html

{code}
   <bean id="activemq" class="org.apache.activemq.camel.component.ActiveMQComponent">
    <property name="brokerURL" value="tcp://localhost:61616"/>
  </bean>
{code}

> New JMS connection being created for every message
> --------------------------------------------------
>
>                 Key: CAMEL-604
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-604
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-jms
>    Affects Versions: 1.3.0
>            Reporter: Eric Levin
>         Attachments: ActiveMQ-Camel-Test.zip, after 130 messages being sent.jpg, falsealarm.jpg
>
>
> A new connection is being created / shutdown for every message that is sent through my ActiveMQ JMSComponent.  I thought this issue had been resolved for Camel 1.3; however, as shown within the example project, it doesn't seem to be.  This is very concerning for rapidly produced messages as there is alot of overhead with creating a new connection.
> Forum posting on this issue: http://www.nabble.com/New-connection-being-created-for-every-message-(post-1.3-camel)-td17684874s22882.html
> Steps to running the attached sample:
> -Have an instance of ActiveMQ running (localhost to the test app) with openwire exposed on port 61616 (the default port)
> -After extracting the example project, simply run 'mvn test' and it will begin sending messages through Camel
> -Open JConsole and look under the Connections for localhost broker - you will notice the suffix on connections increasing very quickly as connections are being opened/torn down for every message sent from the test app.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAMEL-604) New JMS connection being created for every message

Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/activemq/browse/CAMEL-604?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Claus Ibsen updated CAMEL-604:
------------------------------

    Attachment: falsealarm.jpg

Ah I figured it out. When I stopped the unit tests they are not properly shutdown, so I had 5-10 rouge java processes still sending messages to ActiveMQ.

Now I killed them all and started again. After sending more than 660 messages I still only have 2 connections that I started with.

> New JMS connection being created for every message
> --------------------------------------------------
>
>                 Key: CAMEL-604
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-604
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-jms
>    Affects Versions: 1.3.0
>            Reporter: Eric Levin
>         Attachments: ActiveMQ-Camel-Test.zip, after 130 messages being sent.jpg, falsealarm.jpg
>
>
> A new connection is being created / shutdown for every message that is sent through my ActiveMQ JMSComponent.  I thought this issue had been resolved for Camel 1.3; however, as shown within the example project, it doesn't seem to be.  This is very concerning for rapidly produced messages as there is alot of overhead with creating a new connection.
> Forum posting on this issue: http://www.nabble.com/New-connection-being-created-for-every-message-(post-1.3-camel)-td17684874s22882.html
> Steps to running the attached sample:
> -Have an instance of ActiveMQ running (localhost to the test app) with openwire exposed on port 61616 (the default port)
> -After extracting the example project, simply run 'mvn test' and it will begin sending messages through Camel
> -Open JConsole and look under the Connections for localhost broker - you will notice the suffix on connections increasing very quickly as connections are being opened/torn down for every message sent from the test app.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAMEL-604) New JMS connection being created for every message

Posted by "Eric Levin (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/CAMEL-604?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=43641#action_43641 ] 

Eric Levin commented on CAMEL-604:
----------------------------------

Thanks guys -- sorry I was out of town the last week so didn't see the comments until just now.  The problem was that I noticed a new connection being opened and closed for every message being sent.  I am guessing this is a JMS standard thing, and that is why it showed up with using the JmsComponent instead of the ActiveMQ specific component. Apparently I need to pay more attention as I didn't realize there were 2 different components for AMQ vs. generic JMS component...  I'll test it out, but I'm sure that'll do the trick.  Thanks again!

> New JMS connection being created for every message
> --------------------------------------------------
>
>                 Key: CAMEL-604
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-604
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-jms
>    Affects Versions: 1.3.0
>            Reporter: Eric Levin
>         Attachments: ActiveMQ-Camel-Test.zip, after 130 messages being sent.jpg, falsealarm.jpg
>
>
> A new connection is being created / shutdown for every message that is sent through my ActiveMQ JMSComponent.  I thought this issue had been resolved for Camel 1.3; however, as shown within the example project, it doesn't seem to be.  This is very concerning for rapidly produced messages as there is alot of overhead with creating a new connection.
> Forum posting on this issue: http://www.nabble.com/New-connection-being-created-for-every-message-(post-1.3-camel)-td17684874s22882.html
> Steps to running the attached sample:
> -Have an instance of ActiveMQ running (localhost to the test app) with openwire exposed on port 61616 (the default port)
> -After extracting the example project, simply run 'mvn test' and it will begin sending messages through Camel
> -Open JConsole and look under the Connections for localhost broker - you will notice the suffix on connections increasing very quickly as connections are being opened/torn down for every message sent from the test app.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAMEL-604) New JMS connection being created for every message

Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/CAMEL-604?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=43499#action_43499 ] 

Claus Ibsen commented on CAMEL-604:
-----------------------------------

I does indeed looks a bit strange. I have about 30 connections open after sending about 370 messages.

> New JMS connection being created for every message
> --------------------------------------------------
>
>                 Key: CAMEL-604
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-604
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-jms
>    Affects Versions: 1.3.0
>            Reporter: Eric Levin
>         Attachments: ActiveMQ-Camel-Test.zip, after 130 messages being sent.jpg
>
>
> A new connection is being created / shutdown for every message that is sent through my ActiveMQ JMSComponent.  I thought this issue had been resolved for Camel 1.3; however, as shown within the example project, it doesn't seem to be.  This is very concerning for rapidly produced messages as there is alot of overhead with creating a new connection.
> Forum posting on this issue: http://www.nabble.com/New-connection-being-created-for-every-message-(post-1.3-camel)-td17684874s22882.html
> Steps to running the attached sample:
> -Have an instance of ActiveMQ running (localhost to the test app) with openwire exposed on port 61616 (the default port)
> -After extracting the example project, simply run 'mvn test' and it will begin sending messages through Camel
> -Open JConsole and look under the Connections for localhost broker - you will notice the suffix on connections increasing very quickly as connections are being opened/torn down for every message sent from the test app.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (CAMEL-604) New JMS connection being created for every message

Posted by "James Strachan (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/activemq/browse/CAMEL-604?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

James Strachan resolved CAMEL-604.
----------------------------------

    Resolution: Won't Fix

As Claus said, if you use the activemq component directly - which is what we recommend if you are using ActiveMQ - rather than the JMS component everything works fine.

See the blue info box on the JMS page which describes your issue and why you should use the ActiveMQ component - or explicitly use a JMS pool wrapper around the ActiveMQ connection factory
http://activemq.apache.org/camel/jms.html

Its easier to just use the ActiveMQ component as that does the right thing for you
http://activemq.apache.org/camel/activemq.html


> New JMS connection being created for every message
> --------------------------------------------------
>
>                 Key: CAMEL-604
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-604
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-jms
>    Affects Versions: 1.3.0
>            Reporter: Eric Levin
>         Attachments: ActiveMQ-Camel-Test.zip, after 130 messages being sent.jpg, falsealarm.jpg
>
>
> A new connection is being created / shutdown for every message that is sent through my ActiveMQ JMSComponent.  I thought this issue had been resolved for Camel 1.3; however, as shown within the example project, it doesn't seem to be.  This is very concerning for rapidly produced messages as there is alot of overhead with creating a new connection.
> Forum posting on this issue: http://www.nabble.com/New-connection-being-created-for-every-message-(post-1.3-camel)-td17684874s22882.html
> Steps to running the attached sample:
> -Have an instance of ActiveMQ running (localhost to the test app) with openwire exposed on port 61616 (the default port)
> -After extracting the example project, simply run 'mvn test' and it will begin sending messages through Camel
> -Open JConsole and look under the Connections for localhost broker - you will notice the suffix on connections increasing very quickly as connections are being opened/torn down for every message sent from the test app.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (CAMEL-604) New JMS connection being created for every message

Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/activemq/browse/CAMEL-604?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=43498#action_43498 ] 

Claus Ibsen commented on CAMEL-604:
-----------------------------------

Erik what is the status now? Do you have 130 open connections when you have sent 130 messages?

> New JMS connection being created for every message
> --------------------------------------------------
>
>                 Key: CAMEL-604
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-604
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-jms
>    Affects Versions: 1.3.0
>            Reporter: Eric Levin
>         Attachments: ActiveMQ-Camel-Test.zip, after 130 messages being sent.jpg
>
>
> A new connection is being created / shutdown for every message that is sent through my ActiveMQ JMSComponent.  I thought this issue had been resolved for Camel 1.3; however, as shown within the example project, it doesn't seem to be.  This is very concerning for rapidly produced messages as there is alot of overhead with creating a new connection.
> Forum posting on this issue: http://www.nabble.com/New-connection-being-created-for-every-message-(post-1.3-camel)-td17684874s22882.html
> Steps to running the attached sample:
> -Have an instance of ActiveMQ running (localhost to the test app) with openwire exposed on port 61616 (the default port)
> -After extracting the example project, simply run 'mvn test' and it will begin sending messages through Camel
> -Open JConsole and look under the Connections for localhost broker - you will notice the suffix on connections increasing very quickly as connections are being opened/torn down for every message sent from the test app.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (CAMEL-604) New JMS connection being created for every message

Posted by "Claus Ibsen (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/activemq/browse/CAMEL-604?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Claus Ibsen updated CAMEL-604:
------------------------------

    Attachment: after 130 messages being sent.jpg

I am running your sample against ActiveMQ and have enabled jmx in activemq.

I have sent more than 130 messages and got this JMX output.
I am running on JDK1.5

> New JMS connection being created for every message
> --------------------------------------------------
>
>                 Key: CAMEL-604
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-604
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-jms
>    Affects Versions: 1.3.0
>            Reporter: Eric Levin
>         Attachments: ActiveMQ-Camel-Test.zip, after 130 messages being sent.jpg
>
>
> A new connection is being created / shutdown for every message that is sent through my ActiveMQ JMSComponent.  I thought this issue had been resolved for Camel 1.3; however, as shown within the example project, it doesn't seem to be.  This is very concerning for rapidly produced messages as there is alot of overhead with creating a new connection.
> Forum posting on this issue: http://www.nabble.com/New-connection-being-created-for-every-message-(post-1.3-camel)-td17684874s22882.html
> Steps to running the attached sample:
> -Have an instance of ActiveMQ running (localhost to the test app) with openwire exposed on port 61616 (the default port)
> -After extracting the example project, simply run 'mvn test' and it will begin sending messages through Camel
> -Open JConsole and look under the Connections for localhost broker - you will notice the suffix on connections increasing very quickly as connections are being opened/torn down for every message sent from the test app.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.