<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<body link="#355491" alink="#4262a1" vlink="#355491" style="background: #e2e2e2; margin: 0; padding: 20px;">

<div>
        <table cellpadding="0" bgcolor="#FFFFFF" border="0" cellspacing="0" style="border: 1px solid #dadada; margin-bottom: 30px; width: 100%; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
                <tbody>
                        <tr>

                                <td>

                                        <table border="0" cellpadding="0" cellspacing="0" bgcolor="#FFFFFF" style="border: solid 2px #ccc; background: #dadada; width: 100%; -moz-border-radius: 6px; -webkit-border-radius: 6px;">
                                                <tbody>
                                                        <tr>
                                                                <td bgcolor="#000000" valign="middle" height="58px" style="border-bottom: 1px solid #ccc; padding: 20px; -moz-border-radius-topleft: 3px; -moz-border-radius-topright: 3px; -webkit-border-top-right-radius: 5px; -webkit-border-top-left-radius: 5px;">
                                                                        <h1 style="color: #333333; font: bold 22px Arial, Helvetica, sans-serif; margin: 0; display: block !important;">
                                                                        <!-- To have a header image/logo replace the name below with your img tag -->
                                                                        <!-- Email clients will render the images when the message is read so any image -->
                                                                        <!-- must be made available on a public server, so that all recipients can load the image. -->
                                                                        <a href="http://community.jboss.org/index.jspa" style="text-decoration: none; color: #E1E1E1">JBoss Community</a></h1>
                                                                </td>

                                                        </tr>
                                                        <tr>
                                                                <td bgcolor="#FFFFFF" style="font: normal 12px Arial, Helvetica, sans-serif; color:#333333; padding: 20px;  -moz-border-radius-bottomleft: 4px; -moz-border-radius-bottomright: 4px; -webkit-border-bottom-right-radius: 5px; -webkit-border-bottom-left-radius: 5px;"><h3 style="margin: 10px 0 5px; font-size: 17px; font-weight: normal;">
    Passing Message to Jbpm
</h3>
<span style="margin-bottom: 10px;">
    created by <a href="http://community.jboss.org/people/davidmpaz">David Paz</a> in <i>JBoss ESB Development</i> - <a href="http://community.jboss.org/message/569374#569374">View the full discussion</a>
</span>
<hr style="margin: 20px 0; border: none; background-color: #dadada; height: 1px;">

<div class="jive-rendered-content"><p>Hello, I have a problem and I will appreciate any suggestion about it. This is my scenario:</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>I have several services orchestrated from jbpm, the starter service receive an xml through http, the xml is transformed (smooks) into an ArrayList&lt;User&gt;, the message is mapped to jbpm variable from esb as BODY_CONTENT.</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>My problems start when the process try to pause (I have a timer on it), I think it is because this kind of var is not persistable, this is the exeption</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>08:00:54,449 ERROR <a class="" href="http://community.jboss.org/message/569374#569374">Passing Message to Jbpm</a> Unexpected error delivering message delegator-&amp;gt;JBossMessage[21114107566866487]:PERSISTENT, deliveryId=18org.jbpm.JbpmException: cannot mark externally managed transaction for rollback&#160;&#160;&#160; at org.jbpm.persistence.db.DbPersistenceService.endTransaction(DbPersistenceService.java:129)&#160;&#160;&#160; at org.jbpm.persistence.db.DbPersistenceService.close(DbPersistenceService.java:201)&#160;&#160;&#160; at org.jbpm.svc.Services.close(Services.java:247)&#160;&#160;&#160; at org.jbpm.JbpmContext.close(JbpmContext.java:131)&#160;&#160;&#160; at org.jbpm.command.impl.CommandServiceImpl.execute(CommandServiceImpl.java:79)&#160;&#160;&#160; at org.jboss.soa.esb.services.jbpm.cmd.CommandExecutor.executeJbpmCommand(CommandExecutor.java:279)&#160;&#160;&#160; at org.jboss.soa.esb.services.jbpm.cmd.CommandExecutor.access$100(CommandExecutor.java:51)&#160;&#160;&#160; at org.jboss.soa.esb.services.jbpm.cmd.CommandExecutor$3.execute(CommandExecutor.java:136)&#160;&#160;&#160; at org.jboss.soa.esb.services.jbpm.actions.JBpmCallback.process(JBpmCallback.java:68)&#160;&#160;&#160; at sun.reflect.GeneratedMethodAccessor646.invoke(Unknown Source)&#160;&#160;&#160; at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)&#160;&#160;&#160; at java.lang.reflect.Method.invoke(Method.java:597)&#160;&#160;&#160; at org.jboss.soa.esb.listeners.message.ActionProcessorMethodInfo.processMethods(ActionProcessorMethodInfo.java:102)&#160;&#160;&#160; at org.jboss.soa.esb.listeners.message.OverriddenActionLifecycleProcessor.process(OverriddenActionLifecycleProcessor.java:74)&#160;&#160;&#160; at org.jboss.soa.esb.listeners.message.ActionProcessingPipeline.processPipeline(ActionProcessingPipeline.java:634)&#160;&#160;&#160; at org.jboss.soa.esb.listeners.message.ActionProcessingPipeline.processPipeline(ActionProcessingPipeline.java:588)&#160;&#160;&#160; at org.jboss.soa.esb.listeners.message.ActionProcessingPipeline.process(ActionProcessingPipeline.java:419)&#160;&#160;&#160; at org.jboss.soa.esb.listeners.jca.JcaMessageAwareListener.process(JcaMessageAwareListener.java:163)&#160;&#160;&#160; at org.jboss.soa.esb.listeners.jca.JcaJMSInflowMessageProcessorAdapter.onMessage(JcaJMSInflowMessageProcessorAdapter.java:44)&#160;&#160;&#160; at sun.reflect.GeneratedMethodAccessor645.invoke(Unknown Source)&#160;&#160;&#160; at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)&#160;&#160;&#160; at java.lang.reflect.Method.invoke(Method.java:597)&#160;&#160;&#160; at org.jboss.soa.esb.listeners.jca.BaseJcaInflow$1.invoke(BaseJcaInflow.java:205)&#160;&#160;&#160; at org.jboss.soa.esb.listeners.jca.EndpointProxy.delivery(EndpointProxy.java:258)&#160;&#160;&#160; at org.jboss.soa.esb.listeners.jca.EndpointProxy.invoke(EndpointProxy.java:150)&#160;&#160;&#160; at $Proxy374.onMessage(Unknown Source)&#160;&#160;&#160; at org.jboss.resource.adapter.jms.inflow.JmsServerSession.onMessage(JmsServerSession.java:178)&#160;&#160;&#160; at org.jboss.jms.client.container.ClientConsumer.callOnMessageStatic(ClientConsumer.java:160)&#160;&#160;&#160; at org.jboss.jms.client.container.SessionAspect.handleRun(SessionAspect.java:831)&#160;&#160;&#160; at org.jboss.aop.advice.org.jboss.jms.client.container.SessionAspect_z_handleRun_2046525641.invoke(SessionAspect_z_handleRun_2046525641.java)&#160;&#160;&#160; at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102)&#160;&#160;&#160; at org.jboss.jms.client.container.ClosedInterceptor.invoke(ClosedInterceptor.java:170)&#160;&#160;&#160; at org.jboss.aop.advice.PerInstanceInterceptor.invoke(PerInstanceInterceptor.java:86)&#160;&#160;&#160; at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:102)&#160;&#160;&#160; at org.jboss.jms.client.delegate.ClientSessionDelegate.run(ClientSessionDelegate.java)&#160;&#160;&#160; at org.jboss.jms.client.JBossSession.run(JBossSession.java:199)&#160;&#160;&#160; at org.jboss.resource.adapter.jms.inflow.JmsServerSession.run(JmsServerSession.java:234)&#160;&#160;&#160; at org.jboss.resource.work.WorkWrapper.execute(WorkWrapper.java:205)&#160;&#160;&#160; at org.jboss.util.threadpool.BasicTaskWrapper.run(BasicTaskWrapper.java:260)&#160;&#160;&#160; at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)&#160;&#160;&#160; at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)&#160;&#160;&#160; at java.lang.Thread.run(Thread.java:619)</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>Can anyone propose a possible solution or point me to some direction for achieving this, please.</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>As a work around as I have tried to transform back the Collection into an xml string, so the process doesn't complain when paused. I would like to know how can I use that object model to generate an xml string using Smooks, FreeMarker template (notice I would like to generate back an xml with same structure as received one)</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>Again if someone can point me on the right direction, I will appreciate a lot.</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>If you need more information please I can post configuration files also.</p><p style="min-height: 8pt; height: 8pt; padding: 0px;">&#160;</p><p>Thanks for listen, David</p></div>

<div style="background-color: #f4f4f4; padding: 10px; margin-top: 20px;">
    <p style="margin: 0;">Reply to this message by <a href="http://community.jboss.org/message/569374#569374">going to Community</a></p>
        <p style="margin: 0;">Start a new discussion in JBoss ESB Development at <a href="http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2032">Community</a></p>
</div></td>
                        </tr>
                    </tbody>
                </table>


                </td>
            </tr>
        </tbody>
    </table>

</div>

</body>
</html>