Hi,
Oracle SOA suite has provided the facility to add preferences in your composite process.
These preferences are worked as variables which we can change at runtime from EM console.
Ex: We can use preference variable when we need to define which environment we are working in, preference variables for certain values which do not want to hard code, for certain usernames which are unaware for some other components while invoke our service etc.
So each time there is no need to go to our composite and change the value manually and then redeploy and test.
Instead we can define preference variables and change its values in run time from em console.
Steps to create preference variable:
1. Go to your composite.xml and under implementation.bpel define the property:
Here I am mapping my output variable to num1 x num2 which are defined as pref variables.
3. Deploy and test your multiplication service:
Right click on SOA-Infra –> Administration –> System MBean Browser
under System Mbean Browser follow the below navigation:
oracle.soa.config–>soa_server -->SCAComposite–>(yourCompositeName) ->
SCAcomponent.SCAComposite
This opens up a table, in that
Click on the properties tab and expand properties tab to find out element that contains your defined preference variable.
Here we can change the value field to any.
So after changing its value and click “Apply”.
Oracle SOA suite has provided the facility to add preferences in your composite process.
These preferences are worked as variables which we can change at runtime from EM console.
Ex: We can use preference variable when we need to define which environment we are working in, preference variables for certain values which do not want to hard code, for certain usernames which are unaware for some other components while invoke our service etc.
So each time there is no need to go to our composite and change the value manually and then redeploy and test.
Instead we can define preference variables and change its values in run time from em console.
Steps to create preference variable:
1. Go to your composite.xml and under implementation.bpel define the property:
like ex2: <property name="bpel.preference.EnvName">DEV</property>
2. Go to your .bpel and use this preference variable.
3. Deploy and test your multiplication service:
We are now able to see the multiplied value of num1 and num2 .
4. Now if you want to change the value of the fields then we can directly follow this path:
oracle.soa.config–>soa_server -->SCAComposite–>(yourCompositeName) ->
SCAcomponent.SCAComposite
This opens up a table, in that
Click on the properties tab and expand properties tab to find out element that contains your defined preference variable.
So after changing its value and click “Apply”.
So thats all!
We can now test with different inputs to defined preference variable from em.
Keep exploring SOA! :)
Cheers - Krithika G