You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ode.apache.org by Daniel Luebke <da...@inf.uni-hannover.de> on 2008/11/27 14:23:52 UTC

Problem calling/executing async BPEL Process

Hi everyone,

I'm new to this list and have read much of the archives while looking
for a solution to my problem. My name is Daniel and I'm working at the
University of Hannover, Germany. For a lecture, I want to prepare an
async BPEL process running on top of Apache ODE.

I created the process using the Eclipse BPEL Plug-in. The receive and
invoke activities look like this:

<bpel:receive name="receiveInput" partnerLink="client"
			portType="tns:AsyncBPEL" operation="initiate" variable="input"
			createInstance="yes">
		</bpel:receive>

<bpel:invoke name="callbackClient" partnerLink="client"
			portType="tns:AsyncBPELCallback" operation="onResult" inputVariable="output" />


A comment states that WS-Addressing should care about the endpoint for
the final invoke. However, if I'm calling the process from an Axis
client a NullPointerException is thrown. The request, complete with
WS-Addressing headers looks like this:

<?xml version="1.0" encoding="http://schemas.xmlsoap.org/soap/envelope/"
standalone="no"?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Header xmlns:wsa="http://www.w3.org/2005/08/addressing">
<wsa:To>http://localhost:8081/ode/processes/AsyncBPEL</wsa:To>
<wsa:ReplyTo>
<wsa:Address>http://130.75.33.229:7777/axis2/services/anonService2/</wsa:Address>
</wsa:ReplyTo>
<wsa:MessageID>urn:uuid:4ABAF38975E8ACD1DC1227791017047</wsa:MessageID>
<wsa:Action>http://asyncbpel/initiate</wsa:Action>
</soapenv:Header>
<soapenv:Body>
<axis2ns1:AsyncBPELRequest xmlns:axis2ns1="http://asyncbpel">
<axis2ns2:input xmlns:axis2ns2="http://asyncbpel">Hallo</axis2ns2:input>
</axis2ns1:AsyncBPELRequest>
</soapenv:Body>
</soapenv:Envelope>

The log from ODE is as follows:
DEBUG - GeronimoLog.debug(66) | Found a header in incoming message,
checking if there are endpoints there.
DEBUG - GeronimoLog.debug(66) | Received one-way message for
AsyncBPEL.{http://asyncbpel}initiate
DEBUG - GeronimoLog.debug(66) | Starting transaction.
DEBUG - GeronimoLog.debug(66) | Routed: svcQname
{http://asyncbpel}AsyncBPELService -->
BpelProcess[{http://asyncbpel}AsyncBPEL-4]
DEBUG - GeronimoLog.debug(66) | ODE routed to operation Operation:
name=initiate
style=ONE_WAY,0
Input: name=null
Message: name={http://asyncbpel}AsyncBPELRequestMessage
Part: name=payload
elementName={http://asyncbpel}AsyncBPELRequest from service
{http://asyncbpel}AsyncBPELService
DEBUG - GeronimoLog.debug(66) | Invoking ODE using MEX
{MyRoleMex#hqejbhcnphr3s853g4ob0q [Client hqejbhcnphr3s853g4ob0p]
calling {http://asyncbpel}AsyncBPELService.initiate(...)}
DEBUG - GeronimoLog.debug(66) | Message content:  <?xml version="1.0"
encoding="UTF-8"?>
<message><payload><AsyncBPELRequest xmlns="http://asyncbpel"
xmlns:axis2ns1="http://asyncbpel"
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"><input
xmlns:axis2ns2="http://asyncbpel">Hallo</input></AsyncBPELRequest></payload></message>
DEBUG - GeronimoLog.debug(66) | Routed: svcQname
{http://asyncbpel}AsyncBPELService -->
BpelProcess[{http://asyncbpel}AsyncBPEL-4]
DEBUG - GeronimoLog.debug(66) | invoke() EPR= null ==>
BpelProcess[{http://asyncbpel}AsyncBPEL-4]
DEBUG - GeronimoLog.debug(66) | Commiting ODE MEX
{MyRoleMex#hqejbhcnphr3s853g4ob0q [Client hqejbhcnphr3s853g4ob0p]
calling {http://asyncbpel}AsyncBPELService.initiate(...)}
DEBUG - GeronimoLog.debug(66) | Commiting transaction.
DEBUG - GeronimoLog.debug(66) | Releasing mex hqejbhcnphr3s853g4ob0q
DEBUG - GeronimoLog.debug(66) | >>
handleWorkEvent(jobData={mexid=hqejbhcnphr3s853g4ob0q,
pid={http://asyncbpel}AsyncBPEL-4, type=INVOKE_INTERNAL})
DEBUG - GeronimoLog.debug(66) | InvokeInternal event for mexid
hqejbhcnphr3s853g4ob0q
DEBUG - GeronimoLog.debug(66) | GET MEX property
org.apache.ode.bpel.myRoleSessionId = null
DEBUG - GeronimoLog.debug(66) | GET MEX property
org.apache.ode.bpel.myRoleSessionId = null
DEBUG - GeronimoLog.debug(66) | GET MEX property
org.apache.ode.bpel.partnerRoleSessionId = null
DEBUG - GeronimoLog.debug(66) | INPUTMSG: 12.initiate: MSG RCVD keys=[]
mySessionId=null partnerSessionId=null
DEBUG - GeronimoLog.debug(66) | INPUTMSG: 12.initiate: routing failed,
CREATING NEW INSTANCE
DEBUG - GeronimoLog.debug(66) | BpelRuntimeContextImpl created for
instance 301. INDEXED STATE={}
DEBUG - GeronimoLog.debug(66) | SELECT: PickResponseChannel#9: USING
CORRELATOR 12.initiate
DEBUG - GeronimoLog.debug(66) | SELECT: PickResponseChannel#9: CHECKING
for NEW INSTANCE match
DEBUG - GeronimoLog.debug(66) | INPUTMSGMATCH: Changing process instance
state from ready to active
DEBUG - GeronimoLog.debug(66) | SELECT: PickResponseChannel#9: FOUND
match for NEW instance mexRef={MyRoleMex#hqejbhcnphr3s853g4ob0q [Client
hqejbhcnphr3s853g4ob0p] calling
{http://asyncbpel}AsyncBPELService.initiate(...)}
DEBUG - GeronimoLog.debug(66) | INVOKING PARTNER:
partnerLink={PartnerLinkInstance
partnerLinkDecl=OPartnerLink#12,scopeInstanceId=351}, op=onResult
channel=null)
DEBUG - GeronimoLog.debug(66) | INVOKE PARTNER (SEP):
sessionId=hqejbhcnphr3s853g4ob0s partnerSessionId=null
DEBUG - GeronimoLog.debug(66) | Routed: svcQname
{http://asyncbpel}AsyncBPELService -->
BpelProcess[{http://asyncbpel}AsyncBPEL-4]
DEBUG - GeronimoLog.debug(66) | Routed: svcQname
{http://asyncbpel}AsyncBPELService -->
BpelProcess[{http://asyncbpel}AsyncBPEL-4]
DEBUG - GeronimoLog.debug(66) | Invoking in a p2p interaction,
partnerrole {PartnerRoleMex#hqejbhcnphr3s853g4ob0t [PID
{http://asyncbpel}AsyncBPEL-4] calling null.onResult(...)} - myrole
{MyRoleMex#hqejbhcnphr3s853g4ob0u [Client hqejbhcnphr3s853g4ob0t]
calling {http://asyncbpel}AsyncBPELService.onResult(...)}
DEBUG - GeronimoLog.debug(66) | Setting myRoleMex session ids for p2p
interaction, mySession null - partnerSess hqejbhcnphr3s853g4ob0s
DEBUG - GeronimoLog.debug(66) | SET MEX property
org.apache.ode.bpel.partnerRoleSessionId = hqejbhcnphr3s853g4ob0s
DEBUG - GeronimoLog.debug(66) | Routed: svcQname
{http://asyncbpel}AsyncBPELService -->
BpelProcess[{http://asyncbpel}AsyncBPEL-4]
DEBUG - GeronimoLog.debug(66) | invoke() EPR= null ==>
BpelProcess[{http://asyncbpel}AsyncBPEL-4]
ERROR - GeronimoLog.error(108) | Method "run" in class
"org.apache.ode.bpel.runtime.INVOKE" threw an unexpected exception.
java.lang.NullPointerException

I'm a little bit surpised by the "one-way message" but I wonder why ODE
cannot resolve the final invoke.
Has anyone any ideas?

Thanks in advance

Daniel

Re: Problem calling/executing async BPEL Process

Posted by Tammo van Lessen <tv...@gmail.com>.
Alex Boisvert wrote:
> I'm not sure I followed the entire conversation but this sounds interesting
> and useful.
> 
> Are you saying you can perform a request-response WSDL operation over 2
> separate HTTP channels?    I'm curious as to how the mechanics of this works
> in Axis2 and whether this message exchange would be recoverable (e.g. if the
> server goes down in-between)

Exactly. I've attached the example. If you want to give it a try, you'd
need an axis2 repository with an axis2.xml and the addressing module. On
the Ode side take the recent trunk war, engage the addressing module in
the axis2.xml and deploy the helloWorld2 example. Then you can
(hopefully) try the client.

> 
> I'm guessing the existing "mex.timeout" endpoint property could be used to
> configure the timeout for the exchange.  It's probably worth trying...

Yeah, but how should the timeout look for a process with a
      <wait>
        <for>'PT1Y'</for>
      </wait>
lasting for one year? I think its more a conceptual issue that even a
synchronous process can last very long. I'm not entirely sure how the
Axis2-IL-engine-bridge tackles this but at the first look I saw a
invokeBlocking which seems to me like it's waiting until the process
completes (i.e. the MEX completes).

Cheers,
  Tammo

Re: Problem calling/executing async BPEL Process

Posted by Alex Boisvert <bo...@intalio.com>.
On Wed, Dec 17, 2008 at 2:00 PM, Tammo van Lessen <tv...@gmail.com>wrote:

> Well, it works partially. The headers are evaluated correctly and the
> response is sent via the 2nd HTTP channel, however the whole
> processing must not last longer than a specified timeout (~30 seconds)
> as the invocation is blocking and finally results in an unwanted and
> unneeded timeout. I'll open a bug for that (for further discussion).


I'm not sure I followed the entire conversation but this sounds interesting
and useful.

Are you saying you can perform a request-response WSDL operation over 2
separate HTTP channels?    I'm curious as to how the mechanics of this works
in Axis2 and whether this message exchange would be recoverable (e.g. if the
server goes down in-between)

I'm guessing the existing "mex.timeout" endpoint property could be used to
configure the timeout for the exchange.  It's probably worth trying...

alex

Re: Problem calling/executing async BPEL Process

Posted by Tammo van Lessen <tv...@gmail.com>.
On Wed, Dec 17, 2008 at 17:53, Tammo van Lessen <tv...@gmail.com> wrote:
> IMO there's a fourth option: The ws-addr soap/wsdl bindings for
> asynchronous IN_OUT MEPs. At least for such simple two-way interactions
> this works fine* but is of course not a replacement for a correlation
> mechanism that can deal with more complex message exchanges. I agree
> with Daniel that a standard compliant way would be nice. IMO this can be
> achieved by placing the session ID in a ReferenceParameter.
>
> *by "fine" I mean using the latest head, the addressing module engaged
> and invoking the HelloWorld2 process with a ReplyTo header set.

Well, it works partially. The headers are evaluated correctly and the
response is sent via the 2nd HTTP channel, however the whole
processing must not last longer than a specified timeout (~30 seconds)
as the invocation is blocking and finally results in an unwanted and
unneeded timeout. I'll open a bug for that (for further discussion).

Cheers,
  Tammo


-- 
Tammo van Lessen - tvanlessen@gmail.com - http://www.taval.de

Re: Problem calling/executing async BPEL Process

Posted by Tammo van Lessen <tv...@gmail.com>.
Hi all,

Daniel Luebke wrote:
> Hi,
> 
> There are 3 options for solving this problem, none of which I have tried
> yet (and I think Tammo did neither):
> 1. Develop an Axis2 module that adds a dispatcher to the callback
> service. The dispatcher shall route the message using the intalio
> headers to the matching request (quite some work to do, however reusable)
> 2. Add WS-Addressing to ODE (in my opinion the cleanest solution;
> standards-compliant, however it is an even larger change and there has
> some conceptional work to be done to make it work)
> 3. Develop a custom service that is deployed at the client-side and do
> not use the default callback service offered by Axis2.

IMO there's a fourth option: The ws-addr soap/wsdl bindings for
asynchronous IN_OUT MEPs. At least for such simple two-way interactions
this works fine* but is of course not a replacement for a correlation
mechanism that can deal with more complex message exchanges. I agree
with Daniel that a standard compliant way would be nice. IMO this can be
achieved by placing the session ID in a ReferenceParameter.

*by "fine" I mean using the latest head, the addressing module engaged
and invoking the HelloWorld2 process with a ReplyTo header set.

> So far, this is our status, and I like to thank Tammo again for his time
> and patience.

You're welcome :)

Cheers,
  Tammo

Re: Problem calling/executing async BPEL Process

Posted by Daniel Luebke <da...@inf.uni-hannover.de>.
Hi,

first sorry for attaching the bpelex and not the bpel file.
For not leaving this thread open, I like to share the results of my
off-line discussion with Tammo (who I want to thank very much at this
point, especially for his patience).
My initial problem was that I wanted to implement a BPEL process that is
called asynchronously. My first mistake was in the WSDL because I
accidently created one service with two ports instead of two services.
However, calling the BPEL process with Axis2 still didn't work. After
some investigation and although Tammo fixed one bug in ODE when called
with a one-way-message (http://issues.apache.org/jira/browse/ODE-464),
it is still not possible to easily call the process from Axis2. This is
because Axis2 uses WS-Addressing and ODE uses intalio-specific headers.
It is possible to add these headers in Axis2 so that the processes is
called correctly. However, ODE discards the WS-Addressing headers and
replies with the intalio headers only. Therefore, the Axis2 callback
service cannot correlate the answer to the request.
There are 3 options for solving this problem, none of which I have tried
yet (and I think Tammo did neither):
1. Develop an Axis2 module that adds a dispatcher to the callback
service. The dispatcher shall route the message using the intalio
headers to the matching request (quite some work to do, however reusable)
2. Add WS-Addressing to ODE (in my opinion the cleanest solution;
standards-compliant, however it is an even larger change and there has
some conceptional work to be done to make it work)
3. Develop a custom service that is deployed at the client-side and do
not use the default callback service offered by Axis2.

So far, this is our status, and I like to thank Tammo again for his time
and patience.

Daniel

Daniel Luebke schrieb:
> Hi,
>
> of course. Sorry for not attaching it the first time. I added a service
> for both ports (request and callback). I also tried it with two services
> which resulted in a different error message but still didn't work.
>
> Daniel
>
> Alex Boisvert schrieb:
>   
>> Hi Daniel,
>>
>> We'll need your full BPEL deployment bundle to diagnose.  For some reason,
>> the engine thinks you're doing a process-to-process invocation instead of
>> calling back the client.    We don't have enough information to tell why.
>>
>> alex
>>
>>
>> On Thu, Nov 27, 2008 at 5:23 AM, Daniel Luebke <
>> daniel.luebke@inf.uni-hannover.de> wrote:
>>
>>   
>>     
>>> Hi everyone,
>>>
>>> I'm new to this list and have read much of the archives while looking
>>> for a solution to my problem. My name is Daniel and I'm working at the
>>> University of Hannover, Germany. For a lecture, I want to prepare an
>>> async BPEL process running on top of Apache ODE.
>>>
>>> I created the process using the Eclipse BPEL Plug-in. The receive and
>>> invoke activities look like this:
>>>
>>> <bpel:receive name="receiveInput" partnerLink="client"
>>>                        portType="tns:AsyncBPEL" operation="initiate"
>>> variable="input"
>>>                        createInstance="yes">
>>>                </bpel:receive>
>>>
>>> <bpel:invoke name="callbackClient" partnerLink="client"
>>>                        portType="tns:AsyncBPELCallback"
>>> operation="onResult" inputVariable="output" />
>>>
>>>
>>> A comment states that WS-Addressing should care about the endpoint for
>>> the final invoke. However, if I'm calling the process from an Axis
>>> client a NullPointerException is thrown. The request, complete with
>>> WS-Addressing headers looks like this:
>>>
>>> <?xml version="1.0" encoding="http://schemas.xmlsoap.org/soap/envelope/"
>>> standalone="no"?>
>>> <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/
>>> ">
>>> <soapenv:Header xmlns:wsa="http://www.w3.org/2005/08/addressing">
>>> <wsa:To>http://localhost:8081/ode/processes/AsyncBPEL</wsa:To>
>>> <wsa:ReplyTo>
>>> <wsa:Address>http://130.75.33.229:7777/axis2/services/anonService2/
>>> </wsa:Address>
>>> </wsa:ReplyTo>
>>> <wsa:MessageID>urn:uuid:4ABAF38975E8ACD1DC1227791017047</wsa:MessageID>
>>> <wsa:Action>http://asyncbpel/initiate</wsa:Action>
>>> </soapenv:Header>
>>> <soapenv:Body>
>>> <axis2ns1:AsyncBPELRequest xmlns:axis2ns1="http://asyncbpel">
>>> <axis2ns2:input xmlns:axis2ns2="http://asyncbpel">Hallo</axis2ns2:input>
>>> </axis2ns1:AsyncBPELRequest>
>>> </soapenv:Body>
>>> </soapenv:Envelope>
>>>
>>> The log from ODE is as follows:
>>> DEBUG - GeronimoLog.debug(66) | Found a header in incoming message,
>>> checking if there are endpoints there.
>>> DEBUG - GeronimoLog.debug(66) | Received one-way message for
>>> AsyncBPEL.{http://asyncbpel}initiate
>>> DEBUG - GeronimoLog.debug(66) | Starting transaction.
>>> DEBUG - GeronimoLog.debug(66) | Routed: svcQname
>>> {http://asyncbpel}AsyncBPELService -->
>>> BpelProcess[{http://asyncbpel}AsyncBPEL-4]
>>> DEBUG - GeronimoLog.debug(66) | ODE routed to operation Operation:
>>> name=initiate
>>> style=ONE_WAY,0
>>> Input: name=null
>>> Message: name={http://asyncbpel}AsyncBPELRequestMessage
>>> Part: name=payload
>>> elementName={http://asyncbpel}AsyncBPELRequest from service
>>> {http://asyncbpel}AsyncBPELService
>>> DEBUG - GeronimoLog.debug(66) | Invoking ODE using MEX
>>> {MyRoleMex#hqejbhcnphr3s853g4ob0q [Client hqejbhcnphr3s853g4ob0p]
>>> calling {http://asyncbpel}AsyncBPELService.initiate(...)}
>>> DEBUG - GeronimoLog.debug(66) | Message content:  <?xml version="1.0"
>>> encoding="UTF-8"?>
>>> <message><payload><AsyncBPELRequest xmlns="http://asyncbpel"
>>> xmlns:axis2ns1="http://asyncbpel"
>>> xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"><input
>>> xmlns:axis2ns2="http://asyncbpel
>>> ">Hallo</input></AsyncBPELRequest></payload></message>
>>> DEBUG - GeronimoLog.debug(66) | Routed: svcQname
>>> {http://asyncbpel}AsyncBPELService -->
>>> BpelProcess[{http://asyncbpel}AsyncBPEL-4]
>>> DEBUG - GeronimoLog.debug(66) | invoke() EPR= null ==>
>>> BpelProcess[{http://asyncbpel}AsyncBPEL-4]
>>> DEBUG - GeronimoLog.debug(66) | Commiting ODE MEX
>>> {MyRoleMex#hqejbhcnphr3s853g4ob0q [Client hqejbhcnphr3s853g4ob0p]
>>> calling {http://asyncbpel}AsyncBPELService.initiate(...)}
>>> DEBUG - GeronimoLog.debug(66) | Commiting transaction.
>>> DEBUG - GeronimoLog.debug(66) | Releasing mex hqejbhcnphr3s853g4ob0q
>>> DEBUG - GeronimoLog.debug(66) | >>
>>> handleWorkEvent(jobData={mexid=hqejbhcnphr3s853g4ob0q,
>>> pid={http://asyncbpel}AsyncBPEL-4, type=INVOKE_INTERNAL})
>>> DEBUG - GeronimoLog.debug(66) | InvokeInternal event for mexid
>>> hqejbhcnphr3s853g4ob0q
>>> DEBUG - GeronimoLog.debug(66) | GET MEX property
>>> org.apache.ode.bpel.myRoleSessionId = null
>>> DEBUG - GeronimoLog.debug(66) | GET MEX property
>>> org.apache.ode.bpel.myRoleSessionId = null
>>> DEBUG - GeronimoLog.debug(66) | GET MEX property
>>> org.apache.ode.bpel.partnerRoleSessionId = null
>>> DEBUG - GeronimoLog.debug(66) | INPUTMSG: 12.initiate: MSG RCVD keys=[]
>>> mySessionId=null partnerSessionId=null
>>> DEBUG - GeronimoLog.debug(66) | INPUTMSG: 12.initiate: routing failed,
>>> CREATING NEW INSTANCE
>>> DEBUG - GeronimoLog.debug(66) | BpelRuntimeContextImpl created for
>>> instance 301. INDEXED STATE={}
>>> DEBUG - GeronimoLog.debug(66) | SELECT: PickResponseChannel#9: USING
>>> CORRELATOR 12.initiate
>>> DEBUG - GeronimoLog.debug(66) | SELECT: PickResponseChannel#9: CHECKING
>>> for NEW INSTANCE match
>>> DEBUG - GeronimoLog.debug(66) | INPUTMSGMATCH: Changing process instance
>>> state from ready to active
>>> DEBUG - GeronimoLog.debug(66) | SELECT: PickResponseChannel#9: FOUND
>>> match for NEW instance mexRef={MyRoleMex#hqejbhcnphr3s853g4ob0q [Client
>>> hqejbhcnphr3s853g4ob0p] calling
>>> {http://asyncbpel}AsyncBPELService.initiate(...)}
>>> DEBUG - GeronimoLog.debug(66) | INVOKING PARTNER:
>>> partnerLink={PartnerLinkInstance
>>> partnerLinkDecl=OPartnerLink#12,scopeInstanceId=351}, op=onResult
>>> channel=null)
>>> DEBUG - GeronimoLog.debug(66) | INVOKE PARTNER (SEP):
>>> sessionId=hqejbhcnphr3s853g4ob0s partnerSessionId=null
>>> DEBUG - GeronimoLog.debug(66) | Routed: svcQname
>>> {http://asyncbpel}AsyncBPELService -->
>>> BpelProcess[{http://asyncbpel}AsyncBPEL-4]
>>> DEBUG - GeronimoLog.debug(66) | Routed: svcQname
>>> {http://asyncbpel}AsyncBPELService -->
>>> BpelProcess[{http://asyncbpel}AsyncBPEL-4]
>>> DEBUG - GeronimoLog.debug(66) | Invoking in a p2p interaction,
>>> partnerrole {PartnerRoleMex#hqejbhcnphr3s853g4ob0t [PID
>>> {http://asyncbpel}AsyncBPEL-4] calling null.onResult(...)} - myrole
>>> {MyRoleMex#hqejbhcnphr3s853g4ob0u [Client hqejbhcnphr3s853g4ob0t]
>>> calling {http://asyncbpel}AsyncBPELService.onResult(...)}
>>> DEBUG - GeronimoLog.debug(66) | Setting myRoleMex session ids for p2p
>>> interaction, mySession null - partnerSess hqejbhcnphr3s853g4ob0s
>>> DEBUG - GeronimoLog.debug(66) | SET MEX property
>>> org.apache.ode.bpel.partnerRoleSessionId = hqejbhcnphr3s853g4ob0s
>>> DEBUG - GeronimoLog.debug(66) | Routed: svcQname
>>> {http://asyncbpel}AsyncBPELService -->
>>> BpelProcess[{http://asyncbpel}AsyncBPEL-4]
>>> DEBUG - GeronimoLog.debug(66) | invoke() EPR= null ==>
>>> BpelProcess[{http://asyncbpel}AsyncBPEL-4]
>>> ERROR - GeronimoLog.error(108) | Method "run" in class
>>> "org.apache.ode.bpel.runtime.INVOKE" threw an unexpected exception.
>>> java.lang.NullPointerException
>>>
>>> I'm a little bit surpised by the "one-way message" but I wonder why ODE
>>> cannot resolve the final invoke.
>>> Has anyone any ideas?
>>>
>>> Thanks in advance
>>>
>>> Daniel
>>>
>>>     
>>>       
>>   
>>     
>
>
>   


-- 
Dr.-Ing. Daniel Lübke
Leibniz Universität Hannover
Welfengarten 1
D-30167 Hannover
Tel. +49 511 762 19672
Fax  +49 511 762 19679



Re: Problem calling/executing async BPEL Process

Posted by Daniel Luebke <da...@inf.uni-hannover.de>.
Hi,

of course. Sorry for not attaching it the first time. I added a service
for both ports (request and callback). I also tried it with two services
which resulted in a different error message but still didn't work.

Daniel

Alex Boisvert schrieb:
> Hi Daniel,
>
> We'll need your full BPEL deployment bundle to diagnose.  For some reason,
> the engine thinks you're doing a process-to-process invocation instead of
> calling back the client.    We don't have enough information to tell why.
>
> alex
>
>
> On Thu, Nov 27, 2008 at 5:23 AM, Daniel Luebke <
> daniel.luebke@inf.uni-hannover.de> wrote:
>
>   
>> Hi everyone,
>>
>> I'm new to this list and have read much of the archives while looking
>> for a solution to my problem. My name is Daniel and I'm working at the
>> University of Hannover, Germany. For a lecture, I want to prepare an
>> async BPEL process running on top of Apache ODE.
>>
>> I created the process using the Eclipse BPEL Plug-in. The receive and
>> invoke activities look like this:
>>
>> <bpel:receive name="receiveInput" partnerLink="client"
>>                        portType="tns:AsyncBPEL" operation="initiate"
>> variable="input"
>>                        createInstance="yes">
>>                </bpel:receive>
>>
>> <bpel:invoke name="callbackClient" partnerLink="client"
>>                        portType="tns:AsyncBPELCallback"
>> operation="onResult" inputVariable="output" />
>>
>>
>> A comment states that WS-Addressing should care about the endpoint for
>> the final invoke. However, if I'm calling the process from an Axis
>> client a NullPointerException is thrown. The request, complete with
>> WS-Addressing headers looks like this:
>>
>> <?xml version="1.0" encoding="http://schemas.xmlsoap.org/soap/envelope/"
>> standalone="no"?>
>> <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/
>> ">
>> <soapenv:Header xmlns:wsa="http://www.w3.org/2005/08/addressing">
>> <wsa:To>http://localhost:8081/ode/processes/AsyncBPEL</wsa:To>
>> <wsa:ReplyTo>
>> <wsa:Address>http://130.75.33.229:7777/axis2/services/anonService2/
>> </wsa:Address>
>> </wsa:ReplyTo>
>> <wsa:MessageID>urn:uuid:4ABAF38975E8ACD1DC1227791017047</wsa:MessageID>
>> <wsa:Action>http://asyncbpel/initiate</wsa:Action>
>> </soapenv:Header>
>> <soapenv:Body>
>> <axis2ns1:AsyncBPELRequest xmlns:axis2ns1="http://asyncbpel">
>> <axis2ns2:input xmlns:axis2ns2="http://asyncbpel">Hallo</axis2ns2:input>
>> </axis2ns1:AsyncBPELRequest>
>> </soapenv:Body>
>> </soapenv:Envelope>
>>
>> The log from ODE is as follows:
>> DEBUG - GeronimoLog.debug(66) | Found a header in incoming message,
>> checking if there are endpoints there.
>> DEBUG - GeronimoLog.debug(66) | Received one-way message for
>> AsyncBPEL.{http://asyncbpel}initiate
>> DEBUG - GeronimoLog.debug(66) | Starting transaction.
>> DEBUG - GeronimoLog.debug(66) | Routed: svcQname
>> {http://asyncbpel}AsyncBPELService -->
>> BpelProcess[{http://asyncbpel}AsyncBPEL-4]
>> DEBUG - GeronimoLog.debug(66) | ODE routed to operation Operation:
>> name=initiate
>> style=ONE_WAY,0
>> Input: name=null
>> Message: name={http://asyncbpel}AsyncBPELRequestMessage
>> Part: name=payload
>> elementName={http://asyncbpel}AsyncBPELRequest from service
>> {http://asyncbpel}AsyncBPELService
>> DEBUG - GeronimoLog.debug(66) | Invoking ODE using MEX
>> {MyRoleMex#hqejbhcnphr3s853g4ob0q [Client hqejbhcnphr3s853g4ob0p]
>> calling {http://asyncbpel}AsyncBPELService.initiate(...)}
>> DEBUG - GeronimoLog.debug(66) | Message content:  <?xml version="1.0"
>> encoding="UTF-8"?>
>> <message><payload><AsyncBPELRequest xmlns="http://asyncbpel"
>> xmlns:axis2ns1="http://asyncbpel"
>> xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"><input
>> xmlns:axis2ns2="http://asyncbpel
>> ">Hallo</input></AsyncBPELRequest></payload></message>
>> DEBUG - GeronimoLog.debug(66) | Routed: svcQname
>> {http://asyncbpel}AsyncBPELService -->
>> BpelProcess[{http://asyncbpel}AsyncBPEL-4]
>> DEBUG - GeronimoLog.debug(66) | invoke() EPR= null ==>
>> BpelProcess[{http://asyncbpel}AsyncBPEL-4]
>> DEBUG - GeronimoLog.debug(66) | Commiting ODE MEX
>> {MyRoleMex#hqejbhcnphr3s853g4ob0q [Client hqejbhcnphr3s853g4ob0p]
>> calling {http://asyncbpel}AsyncBPELService.initiate(...)}
>> DEBUG - GeronimoLog.debug(66) | Commiting transaction.
>> DEBUG - GeronimoLog.debug(66) | Releasing mex hqejbhcnphr3s853g4ob0q
>> DEBUG - GeronimoLog.debug(66) | >>
>> handleWorkEvent(jobData={mexid=hqejbhcnphr3s853g4ob0q,
>> pid={http://asyncbpel}AsyncBPEL-4, type=INVOKE_INTERNAL})
>> DEBUG - GeronimoLog.debug(66) | InvokeInternal event for mexid
>> hqejbhcnphr3s853g4ob0q
>> DEBUG - GeronimoLog.debug(66) | GET MEX property
>> org.apache.ode.bpel.myRoleSessionId = null
>> DEBUG - GeronimoLog.debug(66) | GET MEX property
>> org.apache.ode.bpel.myRoleSessionId = null
>> DEBUG - GeronimoLog.debug(66) | GET MEX property
>> org.apache.ode.bpel.partnerRoleSessionId = null
>> DEBUG - GeronimoLog.debug(66) | INPUTMSG: 12.initiate: MSG RCVD keys=[]
>> mySessionId=null partnerSessionId=null
>> DEBUG - GeronimoLog.debug(66) | INPUTMSG: 12.initiate: routing failed,
>> CREATING NEW INSTANCE
>> DEBUG - GeronimoLog.debug(66) | BpelRuntimeContextImpl created for
>> instance 301. INDEXED STATE={}
>> DEBUG - GeronimoLog.debug(66) | SELECT: PickResponseChannel#9: USING
>> CORRELATOR 12.initiate
>> DEBUG - GeronimoLog.debug(66) | SELECT: PickResponseChannel#9: CHECKING
>> for NEW INSTANCE match
>> DEBUG - GeronimoLog.debug(66) | INPUTMSGMATCH: Changing process instance
>> state from ready to active
>> DEBUG - GeronimoLog.debug(66) | SELECT: PickResponseChannel#9: FOUND
>> match for NEW instance mexRef={MyRoleMex#hqejbhcnphr3s853g4ob0q [Client
>> hqejbhcnphr3s853g4ob0p] calling
>> {http://asyncbpel}AsyncBPELService.initiate(...)}
>> DEBUG - GeronimoLog.debug(66) | INVOKING PARTNER:
>> partnerLink={PartnerLinkInstance
>> partnerLinkDecl=OPartnerLink#12,scopeInstanceId=351}, op=onResult
>> channel=null)
>> DEBUG - GeronimoLog.debug(66) | INVOKE PARTNER (SEP):
>> sessionId=hqejbhcnphr3s853g4ob0s partnerSessionId=null
>> DEBUG - GeronimoLog.debug(66) | Routed: svcQname
>> {http://asyncbpel}AsyncBPELService -->
>> BpelProcess[{http://asyncbpel}AsyncBPEL-4]
>> DEBUG - GeronimoLog.debug(66) | Routed: svcQname
>> {http://asyncbpel}AsyncBPELService -->
>> BpelProcess[{http://asyncbpel}AsyncBPEL-4]
>> DEBUG - GeronimoLog.debug(66) | Invoking in a p2p interaction,
>> partnerrole {PartnerRoleMex#hqejbhcnphr3s853g4ob0t [PID
>> {http://asyncbpel}AsyncBPEL-4] calling null.onResult(...)} - myrole
>> {MyRoleMex#hqejbhcnphr3s853g4ob0u [Client hqejbhcnphr3s853g4ob0t]
>> calling {http://asyncbpel}AsyncBPELService.onResult(...)}
>> DEBUG - GeronimoLog.debug(66) | Setting myRoleMex session ids for p2p
>> interaction, mySession null - partnerSess hqejbhcnphr3s853g4ob0s
>> DEBUG - GeronimoLog.debug(66) | SET MEX property
>> org.apache.ode.bpel.partnerRoleSessionId = hqejbhcnphr3s853g4ob0s
>> DEBUG - GeronimoLog.debug(66) | Routed: svcQname
>> {http://asyncbpel}AsyncBPELService -->
>> BpelProcess[{http://asyncbpel}AsyncBPEL-4]
>> DEBUG - GeronimoLog.debug(66) | invoke() EPR= null ==>
>> BpelProcess[{http://asyncbpel}AsyncBPEL-4]
>> ERROR - GeronimoLog.error(108) | Method "run" in class
>> "org.apache.ode.bpel.runtime.INVOKE" threw an unexpected exception.
>> java.lang.NullPointerException
>>
>> I'm a little bit surpised by the "one-way message" but I wonder why ODE
>> cannot resolve the final invoke.
>> Has anyone any ideas?
>>
>> Thanks in advance
>>
>> Daniel
>>
>>     
>
>   


-- 
Dr.-Ing. Daniel Lübke
Leibniz Universität Hannover
Welfengarten 1
D-30167 Hannover
Tel. +49 511 762 19672
Fax  +49 511 762 19679


Re: Problem calling/executing async BPEL Process

Posted by Alex Boisvert <bo...@intalio.com>.
Hi Daniel,

We'll need your full BPEL deployment bundle to diagnose.  For some reason,
the engine thinks you're doing a process-to-process invocation instead of
calling back the client.    We don't have enough information to tell why.

alex


On Thu, Nov 27, 2008 at 5:23 AM, Daniel Luebke <
daniel.luebke@inf.uni-hannover.de> wrote:

> Hi everyone,
>
> I'm new to this list and have read much of the archives while looking
> for a solution to my problem. My name is Daniel and I'm working at the
> University of Hannover, Germany. For a lecture, I want to prepare an
> async BPEL process running on top of Apache ODE.
>
> I created the process using the Eclipse BPEL Plug-in. The receive and
> invoke activities look like this:
>
> <bpel:receive name="receiveInput" partnerLink="client"
>                        portType="tns:AsyncBPEL" operation="initiate"
> variable="input"
>                        createInstance="yes">
>                </bpel:receive>
>
> <bpel:invoke name="callbackClient" partnerLink="client"
>                        portType="tns:AsyncBPELCallback"
> operation="onResult" inputVariable="output" />
>
>
> A comment states that WS-Addressing should care about the endpoint for
> the final invoke. However, if I'm calling the process from an Axis
> client a NullPointerException is thrown. The request, complete with
> WS-Addressing headers looks like this:
>
> <?xml version="1.0" encoding="http://schemas.xmlsoap.org/soap/envelope/"
> standalone="no"?>
> <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/
> ">
> <soapenv:Header xmlns:wsa="http://www.w3.org/2005/08/addressing">
> <wsa:To>http://localhost:8081/ode/processes/AsyncBPEL</wsa:To>
> <wsa:ReplyTo>
> <wsa:Address>http://130.75.33.229:7777/axis2/services/anonService2/
> </wsa:Address>
> </wsa:ReplyTo>
> <wsa:MessageID>urn:uuid:4ABAF38975E8ACD1DC1227791017047</wsa:MessageID>
> <wsa:Action>http://asyncbpel/initiate</wsa:Action>
> </soapenv:Header>
> <soapenv:Body>
> <axis2ns1:AsyncBPELRequest xmlns:axis2ns1="http://asyncbpel">
> <axis2ns2:input xmlns:axis2ns2="http://asyncbpel">Hallo</axis2ns2:input>
> </axis2ns1:AsyncBPELRequest>
> </soapenv:Body>
> </soapenv:Envelope>
>
> The log from ODE is as follows:
> DEBUG - GeronimoLog.debug(66) | Found a header in incoming message,
> checking if there are endpoints there.
> DEBUG - GeronimoLog.debug(66) | Received one-way message for
> AsyncBPEL.{http://asyncbpel}initiate
> DEBUG - GeronimoLog.debug(66) | Starting transaction.
> DEBUG - GeronimoLog.debug(66) | Routed: svcQname
> {http://asyncbpel}AsyncBPELService -->
> BpelProcess[{http://asyncbpel}AsyncBPEL-4]
> DEBUG - GeronimoLog.debug(66) | ODE routed to operation Operation:
> name=initiate
> style=ONE_WAY,0
> Input: name=null
> Message: name={http://asyncbpel}AsyncBPELRequestMessage
> Part: name=payload
> elementName={http://asyncbpel}AsyncBPELRequest from service
> {http://asyncbpel}AsyncBPELService
> DEBUG - GeronimoLog.debug(66) | Invoking ODE using MEX
> {MyRoleMex#hqejbhcnphr3s853g4ob0q [Client hqejbhcnphr3s853g4ob0p]
> calling {http://asyncbpel}AsyncBPELService.initiate(...)}
> DEBUG - GeronimoLog.debug(66) | Message content:  <?xml version="1.0"
> encoding="UTF-8"?>
> <message><payload><AsyncBPELRequest xmlns="http://asyncbpel"
> xmlns:axis2ns1="http://asyncbpel"
> xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"><input
> xmlns:axis2ns2="http://asyncbpel
> ">Hallo</input></AsyncBPELRequest></payload></message>
> DEBUG - GeronimoLog.debug(66) | Routed: svcQname
> {http://asyncbpel}AsyncBPELService -->
> BpelProcess[{http://asyncbpel}AsyncBPEL-4]
> DEBUG - GeronimoLog.debug(66) | invoke() EPR= null ==>
> BpelProcess[{http://asyncbpel}AsyncBPEL-4]
> DEBUG - GeronimoLog.debug(66) | Commiting ODE MEX
> {MyRoleMex#hqejbhcnphr3s853g4ob0q [Client hqejbhcnphr3s853g4ob0p]
> calling {http://asyncbpel}AsyncBPELService.initiate(...)}
> DEBUG - GeronimoLog.debug(66) | Commiting transaction.
> DEBUG - GeronimoLog.debug(66) | Releasing mex hqejbhcnphr3s853g4ob0q
> DEBUG - GeronimoLog.debug(66) | >>
> handleWorkEvent(jobData={mexid=hqejbhcnphr3s853g4ob0q,
> pid={http://asyncbpel}AsyncBPEL-4, type=INVOKE_INTERNAL})
> DEBUG - GeronimoLog.debug(66) | InvokeInternal event for mexid
> hqejbhcnphr3s853g4ob0q
> DEBUG - GeronimoLog.debug(66) | GET MEX property
> org.apache.ode.bpel.myRoleSessionId = null
> DEBUG - GeronimoLog.debug(66) | GET MEX property
> org.apache.ode.bpel.myRoleSessionId = null
> DEBUG - GeronimoLog.debug(66) | GET MEX property
> org.apache.ode.bpel.partnerRoleSessionId = null
> DEBUG - GeronimoLog.debug(66) | INPUTMSG: 12.initiate: MSG RCVD keys=[]
> mySessionId=null partnerSessionId=null
> DEBUG - GeronimoLog.debug(66) | INPUTMSG: 12.initiate: routing failed,
> CREATING NEW INSTANCE
> DEBUG - GeronimoLog.debug(66) | BpelRuntimeContextImpl created for
> instance 301. INDEXED STATE={}
> DEBUG - GeronimoLog.debug(66) | SELECT: PickResponseChannel#9: USING
> CORRELATOR 12.initiate
> DEBUG - GeronimoLog.debug(66) | SELECT: PickResponseChannel#9: CHECKING
> for NEW INSTANCE match
> DEBUG - GeronimoLog.debug(66) | INPUTMSGMATCH: Changing process instance
> state from ready to active
> DEBUG - GeronimoLog.debug(66) | SELECT: PickResponseChannel#9: FOUND
> match for NEW instance mexRef={MyRoleMex#hqejbhcnphr3s853g4ob0q [Client
> hqejbhcnphr3s853g4ob0p] calling
> {http://asyncbpel}AsyncBPELService.initiate(...)}
> DEBUG - GeronimoLog.debug(66) | INVOKING PARTNER:
> partnerLink={PartnerLinkInstance
> partnerLinkDecl=OPartnerLink#12,scopeInstanceId=351}, op=onResult
> channel=null)
> DEBUG - GeronimoLog.debug(66) | INVOKE PARTNER (SEP):
> sessionId=hqejbhcnphr3s853g4ob0s partnerSessionId=null
> DEBUG - GeronimoLog.debug(66) | Routed: svcQname
> {http://asyncbpel}AsyncBPELService -->
> BpelProcess[{http://asyncbpel}AsyncBPEL-4]
> DEBUG - GeronimoLog.debug(66) | Routed: svcQname
> {http://asyncbpel}AsyncBPELService -->
> BpelProcess[{http://asyncbpel}AsyncBPEL-4]
> DEBUG - GeronimoLog.debug(66) | Invoking in a p2p interaction,
> partnerrole {PartnerRoleMex#hqejbhcnphr3s853g4ob0t [PID
> {http://asyncbpel}AsyncBPEL-4] calling null.onResult(...)} - myrole
> {MyRoleMex#hqejbhcnphr3s853g4ob0u [Client hqejbhcnphr3s853g4ob0t]
> calling {http://asyncbpel}AsyncBPELService.onResult(...)}
> DEBUG - GeronimoLog.debug(66) | Setting myRoleMex session ids for p2p
> interaction, mySession null - partnerSess hqejbhcnphr3s853g4ob0s
> DEBUG - GeronimoLog.debug(66) | SET MEX property
> org.apache.ode.bpel.partnerRoleSessionId = hqejbhcnphr3s853g4ob0s
> DEBUG - GeronimoLog.debug(66) | Routed: svcQname
> {http://asyncbpel}AsyncBPELService -->
> BpelProcess[{http://asyncbpel}AsyncBPEL-4]
> DEBUG - GeronimoLog.debug(66) | invoke() EPR= null ==>
> BpelProcess[{http://asyncbpel}AsyncBPEL-4]
> ERROR - GeronimoLog.error(108) | Method "run" in class
> "org.apache.ode.bpel.runtime.INVOKE" threw an unexpected exception.
> java.lang.NullPointerException
>
> I'm a little bit surpised by the "one-way message" but I wonder why ODE
> cannot resolve the final invoke.
> Has anyone any ideas?
>
> Thanks in advance
>
> Daniel
>