I was helping a customer with his BPEL in cluster and we needed to follow the flow and on which machine the instance was running.
I simply use a
bpel:exec activity with the following code:
1 2 3 4 5 6 7 8 9
This code is just an example of what could be done. Here I am using java.net code API and put the result in a BPEL global variable using the setVariableData method. Obviously you will use appropriate code to differenciate the different nodes for example the name of the OC4J instance, hostname, … or any interesting value.