Re: Co-ordination protocol and BPEL

Ricky Ho wrote:

> Mark,  I think there are two parts ...
>
> 1) A mechanism to pass context around participants so that they know 
> the piece of work is just part of a bigger transaction.
> 2) A mechanism to terminate this bigger transaction so that each 
> participant will know its final outcome.
>
> My understanding is that WS-C covers the first and WS-Tx covers the 
> second.
>
> However, I don't see how this fits naturally into the current BPEL 
> model. 
>
> BPEL integration with WS-C
> =====================
> How do I associate a "scope" with the "context" of the message that I 
> just receive ? (especially when the <receive> is in the middle of the 
> BPEL process).

I don't think you need to write it in the process definition explicitly. 
When the engine recieves a message that would start a new scope it would 
look for the context. If no context is provided it starts a new scope. 
If a context is provided it would start a new scope and register it as a 
participant in the larger context.

So it would work like the transaction attribute requires in an EJB bean. 
Either you start a new transaction if none was started by the caller, or 
you participate in the caller's transaction.

> I'd like to see something like the following in BPEL
>
> <process>
>     ....
>     <sequence>
>         .....
> *        <receive newScope="true" ....>
>             <scope>
>                 <TerminationHandler> ... </TerminationHandler>
>             </scope>
>         </receive>
> *        .....
>     </sequence>
> </process>
>
>
> BPEL integration with WS-Tx
> ======================
> I'd like to see something like the following in BPEL


For atomic transactions you don't need prepare or commit, you are 
working at a higher level than the code and all that needs to be 
prepared or committed should be done by the engine for you. For BA 
transactions you don't have prepare or commit, every response is an 
indication that all previous steps have been completed (prepared and 
committed). You do need a way to cancel, but this can be done by a fault 
handler (the terminate fault). And you do need a way to compensate and 
this is done by a compensation handler.

This is of course just my speculation based on how you would use 
WS-C/WS-TX with BPML, and the BPEL authors may have a different opinion. 
But I suspect our interpretation on this issue, as most other things, 
would be the same ;-)

arkin

>
> <process>
>     ....
>     <sequence>
>         .....
>         <receive newScope="true" ....>
>             <scope>
> *                <PrepareHandler> ... </PrepareHandler>
>                 <CancelHandler> ... </CancelHandler>
>                 <CommitHandler> ... </CommitHandler>
>                 <CompensationHandler> ... </CompensationHandler>
> *           </scope>
>         </receive>
>         .....
>     </sequence>
> </process>
>
> Thoughts ??
>
> Best regards,
> Ricky

Received on Wednesday, 21 May 2003 22:04:30 UTC