Hi All

I am working on the $subject. The aim of this feature is make it possible
to invoke BPEL processes during Lifecycle state transition in G-Reg for
example with this feature it will be possible to call an BPEL process when
a "Promote" is done.

This is achieved via a transitions executor and the BPEL process will be
invoked through an web web-service call. following is an sample Lifecycle
configuration

<data name="transitionExecution">
 <execution forEvent="Promote"
class="org.wso2.carbon.governance.registry.extensions.executors.BpelExecutor">
 <parameter name="bpel.epr"
value="
http://10.200.3.107:9763/services/AdderProcess.AdderProcesshttpAdderProcessBindingEndpoint/";
/>
 <parameter name="bpel.payload">
<p:AdderProcessRequest xmlns:p="http://wso2.org/bps/sample";>
 <x xmlns="http://wso2.org/bps/sample
">/_system/governance/{@resourcePath}/{@xvalue}</x>
 <y xmlns="http://wso2.org/bps/sample
">/_system/governance/{@resourcePath}/{@yvalue}</y>
 </p:AdderProcessRequest>
</parameter>
</execution>
</data>

The transition execution needs to be provided with the following details


   - End Point Reference of the BPEL

                The End point can either be given directly or trough an
property or artifact attribute
               Ex. <parameter name="bpel.epr"
value="/_system/governance/{@resourcePath}/{@epr}"/>

   - The Payload that needed to invoke the BPEL process.

              The values of the payload can be defined
either directly or trough an property or artifact attribute
Ex.
<data name="transitionExecution">
<execution forEvent="Promote"
class="org.wso2.carbon.governance.registry.extensions.executors.BpelExecutor">
 <parameter name="bpel.epr"
value="/_system/governance/{@resourcePath}/{@epr}"/>
 <parameter name="bpel.payload">
<p:AdderProcessRequest xmlns:p="http://wso2.org/bps/sample";>
 <x xmlns="http://wso2.org/bps/sample
">/_system/governance/{@resourcePath}/{@xvalue}</x>
 <y xmlns="http://wso2.org/bps/sample";>6</y>
 </p:AdderProcessRequest>
</parameter>
</execution>
</data>

   - Optional - Define whether the BPEL process to be called in
   an synchronous or asynchronous manner by default synchronous approach is
   used

               In the asynchronous mode no response will be saved

   - Optional - Define the location to store the response
   - Optional - Define whether the response should be saved as an property
   or artifact attribute
   - Optional - Define the name of the property or attribute to store the
   response


Any feedback and comments are welcome

Thanks
 --
Pulasthi Supun
Software Engineer; WSO2 Inc.; http://wso2.com,
Email: [email protected]
Mobile: +94 (71) 9258281
Blog : http://pulasthisupun.blogspot.com/
Git hub profile: https://github.com/pulasthi
_______________________________________________
Architecture mailing list
[email protected]
https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture

Reply via email to