You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@camel.apache.org by "Claus Ibsen (JIRA)" <ji...@apache.org> on 2008/11/22 12:38:05 UTC

[jira] Created: (CAMEL-1110) JmsProducer has problem with new transactedInOut option not setting acknowledge mode on inout template

JmsProducer has problem with new transactedInOut option not setting acknowledge mode on inout template
------------------------------------------------------------------------------------------------------

                 Key: CAMEL-1110
                 URL: https://issues.apache.org/activemq/browse/CAMEL-1110
             Project: Apache Camel
          Issue Type: Sub-task
          Components: camel-jms
            Reporter: Claus Ibsen
            Assignee: Claus Ibsen
             Fix For: 2.0.0


After debugging for a little while I think the createInOutTemplate in JMSConfiguration needs to cater for acknowledge mode if non transacted


{code}
org.apache.camel.RuntimeCamelException: org.springframework.jms.UncategorizedJmsException: Uncategorized exception occured during JMS processing; nested exception is javax.jms.JMSException: acknowledgeMode SESSION_TRANSACTED cannot be used for an non-transacted Session
	at org.apache.camel.util.ObjectHelper.wrapRuntimeCamelException(ObjectHelper.java:719)
	at org.apache.camel.impl.ProducerCache.send(ProducerCache.java:138)
	at org.apache.camel.impl.DefaultProducerTemplate.send(DefaultProducerTemplate.java:100)
	at org.apache.camel.impl.DefaultProducerTemplate.sendBody(DefaultProducerTemplate.java:104)
	at org.apache.camel.impl.DefaultProducerTemplate.sendBody(DefaultProducerTemplate.java:120)
	at org.apache.camel.impl.DefaultProducerTemplate.requestBody(DefaultProducerTemplate.java:200)
	at org.apache.camel.component.jms.tx.NonTransactedInOutForJmsWithTxnMgrTest.testJmsNonTransactedInOutWithTxnMgr(NonTransactedInOutForJmsWithTxnMgrTest.java:35)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:40)
Caused by: org.springframework.jms.UncategorizedJmsException: Uncategorized exception occured during JMS processing; nested exception is javax.jms.JMSException: acknowledgeMode SESSION_TRANSACTED cannot be used for an non-transacted Session
	at org.springframework.jms.support.JmsUtils.convertJmsAccessException(JmsUtils.java:308)
	at org.springframework.jms.support.JmsAccessor.convertJmsAccessException(JmsAccessor.java:168)
	at org.springframework.jms.core.JmsTemplate.execute(JmsTemplate.java:474)
	at org.apache.camel.component.jms.JmsConfiguration$CamelJmsTemplate.send(JmsConfiguration.java:169)
	at org.apache.camel.component.jms.JmsProducer.process(JmsProducer.java:172)
	at org.apache.camel.impl.ProducerCache.sendExchange(ProducerCache.java:151)
	at org.apache.camel.impl.ProducerCache.send(ProducerCache.java:136)
	... 23 more
Caused by: javax.jms.JMSException: acknowledgeMode SESSION_TRANSACTED cannot be used for an non-transacted Session
	at org.apache.activemq.ActiveMQConnection.createSession(ActiveMQConnection.java:300)
	at org.springframework.jms.support.JmsAccessor.createSession(JmsAccessor.java:196)
	at org.springframework.jms.core.JmsTemplate.execute(JmsTemplate.java:462)
	... 27 more
{code}

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


[jira] Resolved: (CAMEL-1110) JmsProducer has problem with new transactedInOut option not setting acknowledge mode on inout template

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

Claus Ibsen resolved CAMEL-1110.
--------------------------------

    Resolution: Fixed

> JmsProducer has problem with new transactedInOut option not setting acknowledge mode on inout template
> ------------------------------------------------------------------------------------------------------
>
>                 Key: CAMEL-1110
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-1110
>             Project: Apache Camel
>          Issue Type: Sub-task
>          Components: camel-jms
>            Reporter: Claus Ibsen
>            Assignee: Claus Ibsen
>             Fix For: 2.0.0
>
>
> After debugging for a little while I think the createInOutTemplate in JMSConfiguration needs to cater for acknowledge mode if non transacted
> {code}
> org.apache.camel.RuntimeCamelException: org.springframework.jms.UncategorizedJmsException: Uncategorized exception occured during JMS processing; nested exception is javax.jms.JMSException: acknowledgeMode SESSION_TRANSACTED cannot be used for an non-transacted Session
> 	at org.apache.camel.util.ObjectHelper.wrapRuntimeCamelException(ObjectHelper.java:719)
> 	at org.apache.camel.impl.ProducerCache.send(ProducerCache.java:138)
> 	at org.apache.camel.impl.DefaultProducerTemplate.send(DefaultProducerTemplate.java:100)
> 	at org.apache.camel.impl.DefaultProducerTemplate.sendBody(DefaultProducerTemplate.java:104)
> 	at org.apache.camel.impl.DefaultProducerTemplate.sendBody(DefaultProducerTemplate.java:120)
> 	at org.apache.camel.impl.DefaultProducerTemplate.requestBody(DefaultProducerTemplate.java:200)
> 	at org.apache.camel.component.jms.tx.NonTransactedInOutForJmsWithTxnMgrTest.testJmsNonTransactedInOutWithTxnMgr(NonTransactedInOutForJmsWithTxnMgrTest.java:35)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> 	at com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:40)
> Caused by: org.springframework.jms.UncategorizedJmsException: Uncategorized exception occured during JMS processing; nested exception is javax.jms.JMSException: acknowledgeMode SESSION_TRANSACTED cannot be used for an non-transacted Session
> 	at org.springframework.jms.support.JmsUtils.convertJmsAccessException(JmsUtils.java:308)
> 	at org.springframework.jms.support.JmsAccessor.convertJmsAccessException(JmsAccessor.java:168)
> 	at org.springframework.jms.core.JmsTemplate.execute(JmsTemplate.java:474)
> 	at org.apache.camel.component.jms.JmsConfiguration$CamelJmsTemplate.send(JmsConfiguration.java:169)
> 	at org.apache.camel.component.jms.JmsProducer.process(JmsProducer.java:172)
> 	at org.apache.camel.impl.ProducerCache.sendExchange(ProducerCache.java:151)
> 	at org.apache.camel.impl.ProducerCache.send(ProducerCache.java:136)
> 	... 23 more
> Caused by: javax.jms.JMSException: acknowledgeMode SESSION_TRANSACTED cannot be used for an non-transacted Session
> 	at org.apache.activemq.ActiveMQConnection.createSession(ActiveMQConnection.java:300)
> 	at org.springframework.jms.support.JmsAccessor.createSession(JmsAccessor.java:196)
> 	at org.springframework.jms.core.JmsTemplate.execute(JmsTemplate.java:462)
> 	... 27 more
> {code}

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


[jira] Updated: (CAMEL-1110) JmsProducer has problem with new transactedInOut option not setting acknowledge mode on inout template

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

Willem Jiang updated CAMEL-1110:
--------------------------------

    Fix Version/s: 1.5.1

Also merged this patch into the Camel-1.x branch.

> JmsProducer has problem with new transactedInOut option not setting acknowledge mode on inout template
> ------------------------------------------------------------------------------------------------------
>
>                 Key: CAMEL-1110
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-1110
>             Project: Apache Camel
>          Issue Type: Sub-task
>          Components: camel-jms
>            Reporter: Claus Ibsen
>            Assignee: Claus Ibsen
>             Fix For: 1.5.1, 2.0.0
>
>
> After debugging for a little while I think the createInOutTemplate in JMSConfiguration needs to cater for acknowledge mode if non transacted
> {code}
> org.apache.camel.RuntimeCamelException: org.springframework.jms.UncategorizedJmsException: Uncategorized exception occured during JMS processing; nested exception is javax.jms.JMSException: acknowledgeMode SESSION_TRANSACTED cannot be used for an non-transacted Session
> 	at org.apache.camel.util.ObjectHelper.wrapRuntimeCamelException(ObjectHelper.java:719)
> 	at org.apache.camel.impl.ProducerCache.send(ProducerCache.java:138)
> 	at org.apache.camel.impl.DefaultProducerTemplate.send(DefaultProducerTemplate.java:100)
> 	at org.apache.camel.impl.DefaultProducerTemplate.sendBody(DefaultProducerTemplate.java:104)
> 	at org.apache.camel.impl.DefaultProducerTemplate.sendBody(DefaultProducerTemplate.java:120)
> 	at org.apache.camel.impl.DefaultProducerTemplate.requestBody(DefaultProducerTemplate.java:200)
> 	at org.apache.camel.component.jms.tx.NonTransactedInOutForJmsWithTxnMgrTest.testJmsNonTransactedInOutWithTxnMgr(NonTransactedInOutForJmsWithTxnMgrTest.java:35)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> 	at com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:40)
> Caused by: org.springframework.jms.UncategorizedJmsException: Uncategorized exception occured during JMS processing; nested exception is javax.jms.JMSException: acknowledgeMode SESSION_TRANSACTED cannot be used for an non-transacted Session
> 	at org.springframework.jms.support.JmsUtils.convertJmsAccessException(JmsUtils.java:308)
> 	at org.springframework.jms.support.JmsAccessor.convertJmsAccessException(JmsAccessor.java:168)
> 	at org.springframework.jms.core.JmsTemplate.execute(JmsTemplate.java:474)
> 	at org.apache.camel.component.jms.JmsConfiguration$CamelJmsTemplate.send(JmsConfiguration.java:169)
> 	at org.apache.camel.component.jms.JmsProducer.process(JmsProducer.java:172)
> 	at org.apache.camel.impl.ProducerCache.sendExchange(ProducerCache.java:151)
> 	at org.apache.camel.impl.ProducerCache.send(ProducerCache.java:136)
> 	... 23 more
> Caused by: javax.jms.JMSException: acknowledgeMode SESSION_TRANSACTED cannot be used for an non-transacted Session
> 	at org.apache.activemq.ActiveMQConnection.createSession(ActiveMQConnection.java:300)
> 	at org.springframework.jms.support.JmsAccessor.createSession(JmsAccessor.java:196)
> 	at org.springframework.jms.core.JmsTemplate.execute(JmsTemplate.java:462)
> 	... 27 more
> {code}

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