[JBoss jBPM] - Correlation problem
by Turanyi
I have simple process with two operations (process, push).
Process starts by operation "process" and reply with input+"started" then waits for operation "push" and reply input+name+"pushed".
It is example of correlations.
Process can be deployed without problems. But there is problem to start instances.
When I remove <bpws:correlations>...</bpws:correlations> from receive activities process works fine but instances don't correlate of course.
Please help me where I do mistake.
Thank you.
WSDL
| <definitions name="correlwait"
| targetNamespace="http://eclipse.org/bpel/correlwait"
| xmlns:tns="http://eclipse.org/bpel/correlwait"
| xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype"
| xmlns:bpel="http://schemas.xmlsoap.org/ws/2003/03/business-process/"
| xmlns="http://schemas.xmlsoap.org/wsdl/"
| >
|
| <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| TYPE DEFINITION - List of types participating in this BPEL process
| The BPEL Designer will generate default request and response types
| but you can define or import any XML Schema type and use them as part
| of the message types.
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
| <types>
| <schema attributeFormDefault="unqualified" elementFormDefault="qualified"
| targetNamespace="http://eclipse.org/bpel/correlwait"
| xmlns="http://www.w3.org/2001/XMLSchema">
|
| <element name="correlwaitRequest">
| <complexType>
| <sequence>
| <element name="ID" type="int"/>
| <element name="input" type="string"/>
| </sequence>
| </complexType>
| </element>
|
| <element name="correlwaitResponse">
| <complexType>
| <sequence>
| <element name="result" type="string"/>
| </sequence>
| </complexType>
| </element>
|
| <element name="pushwaitRequest">
| <complexType>
| <sequence>
| <element name="ID" type="int"/>
| <element name="name" type="string"/>
| </sequence>
| </complexType>
| </element>
|
| <element name="pushwaitResponse">
| <complexType>
| <sequence>
| <element name="status" type="string"/>
| </sequence>
| </complexType>
| </element>
| </schema>
| </types>
|
|
| <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| MESSAGE TYPE DEFINITION - Definition of the message types used as
| part of the port type defintions
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
| <message name="correlwaitRequestMessage">
| <part name="payload" element="tns:correlwaitRequest"/>
| </message>
| <message name="correlwaitResponseMessage">
| <part name="payload" element="tns:correlwaitResponse"/>
| </message>
| <message name="pushwaitRequestMessage">
| <part name="payload" element="tns:pushwaitRequest"/>
| </message>
| <message name="pushwaitResponseMessage">
| <part name="payload" element="tns:pushwaitResponse"/>
| </message>
|
| <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| PORT TYPE DEFINITION - A port type groups a set of operations into
| a logical service unit.
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
|
| <!-- portType implemented by the correlwait BPEL process -->
| <portType name="correlwait">
| <operation name="process">
| <input message="tns:correlwaitRequestMessage" />
| <output message="tns:correlwaitResponseMessage"/>
| </operation>
| <operation name="push">
| <input message="tns:pushwaitRequestMessage" />
| <output message="tns:pushwaitResponseMessage"/>
| </operation>
| </portType>
|
|
| <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| PARTNER LINK TYPE DEFINITION
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
| <plnk:partnerLinkType name="correlwait">
| <plnk:role name="correlwaitProvider" portType="tns:correlwait"/>
| </plnk:partnerLinkType>
|
|
| <!-- ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| PROPERTY DEFINITION
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -->
| <bpel:property name="IDproperty" type="int"/>
| <bpel:propertyAlias propertyName="tns:IDproperty" messageType="tns:correlwaitRequestMessage" part="payload" query="/tns:payload/ID"/>
| <bpel:propertyAlias propertyName="tns:IDproperty" messageType="tns:pushwaitRequestMessage" part="payload" query="/tns:payload/ID"/>
| </definitions>
|
|
BPEL
| <?xml version="1.0" encoding="UTF-8"?>
| <bpws:process exitOnStandardFault="yes" name="correlwait"
| suppressJoinFailure="yes"
| targetNamespace="http://eclipse.org/bpel/correlwait"
| xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
| xmlns:ns="http://eclipse.org/bpel/correlwaitArtifacts" xmlns:tns="http://eclipse.org/bpel/correlwait">
| <bpws:import importType="http://schemas.xmlsoap.org/wsdl/"
| location="correlwait.wsdl" namespace="http://eclipse.org/bpel/correlwait"/>
| <bpws:partnerLinks>
| <bpws:partnerLink myRole="correlwaitProvider" name="client" partnerLinkType="tns:correlwait"/>
| </bpws:partnerLinks>
| <bpws:variables>
| <bpws:variable messageType="tns:correlwaitRequestMessage" name="input"/>
| <bpws:variable messageType="tns:correlwaitResponseMessage" name="output"/>
| <bpws:variable messageType="tns:pushwaitRequestMessage" name="pushRequest"/>
| <bpws:variable messageType="tns:pushwaitResponseMessage" name="pushResponse"/>
| </bpws:variables>
| <bpws:correlationSets>
| <bpws:correlationSet name="IDCorrelationSet" properties="tns:IDproperty"/>
| </bpws:correlationSets>
| <bpws:sequence name="main">
| <bpws:receive createInstance="yes" name="receiveInput"
| operation="process" partnerLink="client"
| portType="tns:correlwait" variable="input">
| <bpws:correlations>
| <bpws:correlation set="IDCorrelationSet" initiate="yes"/>
| </bpws:correlations>
| </bpws:receive>
| <bpws:assign name="outputAssign" validate="no">
| <bpws:copy>
| <bpws:from><bpws:expression>concat($input.payload/tns:input, ' started.')</bpws:expression></bpws:from>
| <bpws:to variable="output" part="payload" query="/tns:payload/result"/>
| </bpws:copy>
| </bpws:assign>
| <bpws:reply name="replyOutput" operation="process"
| partnerLink="client" portType="tns:correlwait" variable="output"/>
| <bpws:receive name="pushReceive" operation="push"
| partnerLink="client" portType="tns:correlwait" variable="pushRequest">
| </bpws:receive>
| <bpws:assign name="pushAssign" validate="no">
| <bpws:copy>
| <bpws:from>
| <bpws:expression>concat($input.payload/tns:input, ', ', $pushRequest.payload/tns:name, ' pushed.')</bpws:expression>
| </bpws:from>
| <bpws:to variable="pushResponse" part="payload" query="/tns:payload/status"/>
| </bpws:copy>
| </bpws:assign>
| <bpws:reply name="pushReply" operation="push"
| partnerLink="client" portType="tns:correlwait" variable="pushResponse"/>
| </bpws:sequence>
| </bpws:process>
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4180054#4180054
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4180054
15 years, 9 months
[JBoss jBPM] - Re: Dying processes problem
by Turanyi
"kukeltje" wrote : "Turanyi" wrote :
| | Imagine: I deploy process. Everything is ok. Process works.
| |
| It can't just work... process INSTANCES have to be started or signalled
|
I know. "Process works" it means that you look http://serverip:8080/jbossws/services you will see registered endpoind of your process and StartTime is not null - so process is ready to create incances and process INSTANCES can be started or signalled.
"kukeltje" wrote : "Turanyi" wrote :
| | Now I stop JBoss server by ctrl+c. Server shutdown.
| | Ok, this should not be a problem"Turanyi" wrote :
| | After some time I start JBoss server and I see problems with deploy process from tmp...
| What deploy processes from tmp? What problems?
|
When starting JBoss server all services are deployed. On console you can see:
DEBUG [org.jboss.deployment.MainDeployer] Starting deployment of package: file:/usr/jboss/jboss-4.2.2GA/server/default/deploy/process.war
DEBUG [org.jboss.web.WebModule] Starting jboss.web.deployment:war=process.war,id=-184595670
DEBUG [org.jboss.web.tomcat.service.TomcatDeployer] warURL: file:/usr/jboss/jboss-4.2.2.GA/server/default/tmp/deploy/tmp43456process-exp.war/
INFO [org.jboss.web.tomcat.service.TomcatDeployer] deploy, ctxPath=/process, warUrl=.../tmp/deploy/tmp43456process-exp.war/
ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/process]] Error configuring application listener of class org.jbpm.bpel.integration.server.IntegrationConfigurator
ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/process]] Skipped installing application listeners due to previous error(s)
DEBUG [org.jboss.web.WebModule] Starting failed jboss.web.deployment:war=process.war,id=-184595670
DEBUG [org.jboss.util.NestedThrowable] org.jboss.util.NestedThrowable.detectDuplicateNesting=true
org.jboss.deployment.DeploymentException: URL file:/usr/jboss/jboss-4.2.2.GA/server/default/tmp/deploy/tmp43456process-exp.war/ deployment failed
WARN [org.jboss.system.ServiceController] Problem starting service jboss.web.deployment:war=process.war,id=-184595670 org.jboss.deployment.DeploymentException: URL file:/usr/jboss/jboss-4.2.2.GA/server/default/tmp/deploy/tmp43456process-exp.war/ deployment failed
ERROR [org.jboss.deployment.MainDeployer] Could not start deployment: file:/usr/jboss/jboss-4.2.2.GA/server/default/deploy/process.war
org.jboss.deployment.DeploymentException: URL file:/usr/jboss/jboss-4.2.2.GA/server/default/tmp/deploy/tmp43456process-exp.war/ deployment failed
DEBUG [org.jboss.deployment.scanner.URLDeploymentScanner] Failed to deploy: org.jboss.deployment.scanner.URLDeploymentScanner$DeployedURL@f4ff4b2a{ url=file:/usr/jboss/jboss-4.2.2.GA/server/default/deploy/process.war, deployedLastModified=0 }
org.jboss.deployment.DeploymentException: URL file:/usr/jboss/jboss-4.2.2.GA/server/default/tmp/deploy/tmp43456process-exp.war/ deployment failed
--- Incompletely deployed packages ---
org.jboss.deployment.DeploymentInfo@f4ff4b2a { url=file:/usr/jboss/jboss-4.2.2.GA/server/default/deploy/process.war }
deployer: MBeanProxyExt[jboss.web:service=WebServer]
status: Deployment FAILED reason: URL file:/usr/jboss/jboss-4.2.2.GA/server/default/tmp/deploy/tmp43456process-exp.war/ deployment failed
state: FAILED
"kukeltje" wrote : "Turanyi" wrote :
| | I look to jbossws console and I see prosess is not started. Process not respond, process is dead.
| | jbossws console? Never heard of that... process not responding?if it is persistant in the database you have to signal PROCESS INSTANCES again to continue to the next state... does not happen automagically
|
I mean http://serverip:8080/jbossws/services shows StartTime null and process can't start any INSTANCE.
"kukeltje" wrote : "Turanyi" wrote :
| | I have to deploy it again to use it.
| | never heard of that...did you build custom code?
|
:) Me too. No custom code.
"kukeltje" wrote : "Turanyi" wrote :
| | WTF. Is it normal?
| Please no swearing... even I have never done that
|
| You have to be way more specific for us to be able to help you
:) No swearing but it is very disturbing
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4179944#4179944
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4179944
15 years, 9 months