I found a fix for this. On org.jbpm.bpel.relation.jms.RelationContext, comment out one line like following, and initialize portConsumer to null:
| public PortConsumer getPortConsumer(PartnerLinkInstance instance) { | Long instanceId = new Long(instance.getId()); | PortConsumer portConsumer = null; | synchronized (portConsumers) { | //portConsumer = (PortConsumer) portConsumers.get(instanceId); -- commented out to fix the nullpointer exception. | if (portConsumer == null) { | EndpointReference partnerRef = instance.getPartnerReference(); | if (partnerRef == null) { | partnerRef = createPartnerReference(instance.getDefinition()); | instance.setPartnerReference(partnerRef); | log.debug("initialized partner reference: instance=" + instance + | ", reference=" + partnerRef); | } | // select a port from the service catalog | Port port = partnerRef.selectPort(getServiceCatalog()); | log.debug("selected partner port: instance=" + instance + ", port=" + port.getName()); | // create a consumer for that port | portConsumer = new PortConsumer(port); | portConsumers.put(instanceId, portConsumer); | } | } | return portConsumer; | } | The problem was that somehow in my case instance.getId() always returns 0, so the first cached portConsumer was always returned, even when a new one should have been created. The fix basicly bypasses the caching mechanism on portConsumers. And now invoking one service after another works. This is probably the laziest fix. I'll dig more into it and see why jbpm always returns instance with instance id set to 0 in this case when I get a chance. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3954181#3954181 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3954181 Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ JBoss-user mailing list JBoss-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-user