ode-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mike Edwards <mike.edwards.inglen...@gmail.com>
Subject [DISCUSS] How to Provide External initialization of BPEL variables
Date Thu, 09 Jul 2009 15:25:51 GMT
Hi folks,

I am writing as one of the committers on Apache Tuscany, which is using ODE to provide SOA

components using the BPEL langage, combined with other components written in many other languages.

One of the capabilities that Tuscany provides, through its implementation of the Service Component

Architecture (SCA) specification for BPEL, is the capability to provide "external initialization"
BPEL variables.  I am interested in getting a clean implementation of this capability with

So, first, how is this capability described?

The SCA BPEL spec has an extension attribute that is used on a BPEL variable declaration to
that its value should be initialized from SCA metadata, like this:

     <variable name="testName" type="xsd:string" sca-bpel:property="yes"/>

...where sca-bpel is the prefix referring to an SCA namespace:


The related SCA metadata might look something like this:

<component name="TestClient">
    <implementation.bpel process="bpel:ClientInterface_0002"/>
    <service name="TestInvocation">
       <interface.wsdl interface="http://test.sca.oasisopen.org/#wsdl.porttype(TestInvocation)"/>

    <reference name="reference1" target="TEST_ASM_4001Component1/Service1" />
    <property name="testName">ASM_4001</property>

It's that <property/> element that drives the initializer value for the variable within
the BPEL 
process. (Note - this is a trivial case, SCA allows for much more complex setting of data
Note that this DOES NOT imply that the variable is an "external variable" in the ODE sense
- other 
than the initialization, the variable is a standard BPEL variable.

At the moment, there is no clean way of performing this initialization using ODE.  The latest

version of ODE does support the concept of initializer values - what we need is to have some

"external code" invoked at the right time to fetch the data value and set the value into the

I'm interested to hear if you would be willing to consider adding a few extra capabilities
to ODE to 
enable this feature.  I believe that much of what is needed is already in the latest ODE code,
it will need some extra code to organize things.  I think that it might be along these lines:

1) Tweak to the BPEL Compiler code to allow recognition of the sca-bpel:property extension
and for the compiler to generate code that will do initialization of the related variable,
through the invocation of some external extension code at runtime.

2) Tweak to the runtime code to allow for the invocation of external extension code during
initialization, and for that code to be able to assign a value to the variable.

Comments welcome - please tell me if I'm being insane here, for example! I would expect the
folks (probably me!) to write the actual external extension code called at runtime, but the
points would have to be in the core ODE code, both for the compiler and for the runtime.

Yours,  Mike.

View raw message