I have a requirement where I will get a input from a service and I have to pass this input dynamically to file adapter which then retrieved the files from a location based on the input provided and passes it to other service.
I have used one receive activity for getting input parameters and other receive activity for getting files activity, but unfortunately it is not allowing me to do so. How can I design the process,
1. I will get an input from a service.
2. FA has to be invoked for getting files from location specified ( I know that dynamic values can be set inside properties tab), but confused on how to work with two receive activities.
3. And the retrieved files has to be sent to a service.
Edited by: kameshb on Mar 29, 2013 9:59 AM
You can use correlation set for mid-process receive.Try this link..
Hope it helps.
Also make sure that you select *“create Instance”* option only for the 1st receive activity.
Not sure why you need second receive activity(as in your case FA would be an invoke activity), what FA operation are you using?
Edited by: Faiz Haq on Mar 29, 2013 5:31 PM
Please use the Synchronous Read option in the file adapter.
This will suit your current requirement.
1) Your first receive which will get the input from the Service.
2) Have an invoke activity into the file adapter with the synch read operation.
3) Get the file name etc from the input and set them to the properties of the invoke activity
When ever you want to read a file in middle of your bpel process then please go for synch read operation of the file adapter.
Read operation is used to poll files from a specified directory, in most cases it will be first activity(receive) of your BPEL and will create a new instance for you(else use correlation for mid process receive).
As in your case you are dynamically passing input to FA to read a specific file in mid of your process, it should be sync read operation (as suggested by Deepak) wit an invoke activity.
Edited by: Faiz Haq on Mar 30, 2013 1:42 AM
Edited by: Faiz Haq on Mar 30, 2013 1:46 AM