Workflow Web Services
Hello,
Is there a way to generate a web service and have it invoked without requiring a return parameter? I have the process working but I need to have it invoke a few hundred user request tasks that can exist independently and be completed in parallel. The problem occur when I want to cycling through a collection to kick off each of the few hundred user tasks, I have not found a solution that will create all the processes without sitting and waiting for the first one to finish, then the second one, then the third one. I'm sure you get the picture. I would appreciate any idea on how I can get this to run.
If a Web Service isn't the best choice I'm open to any ideas
Thanks
Cary
Filed under: Workflow Solution, Basics, Configuring, Tip/How to, Endpoint Management and Virtualization
Parallel Workflow
I think this is what you're looking for??
Here's an example of parallel workflow. Under videos you'll see a Parallel Workflow video.
However, don't do it this way if you're creating hundreds of tasks. The persistence data that gets stored with the workflow will get massive and cause problems on your server. Instead, create a second workflow for the user request tasks and use the Web Service Caller component generator to create a component to call the second workflow. Doing it this way gives you the asynchronous behavior, like in the parallel workflow example, because when you start a workflow via a web service it returns immediately with the tracking id. If you need the workflow to wait for all the tasks (sub workflows) to complete and merge you can use the Embedded Merge Component which gives you a model that decides if the workflow can continue. Generally, what you’d do in this case is log what’s going on in the database so you can have a simple query that decides if it should continue. For example, in the main workflow I might write a record to a table with attributes related to the overall workflow, like the submitter and the tracking id. I’d have a second table for the tasks that includes the parent tracking id, tracking id and some sort of status. In each sub workflow I’d write a record to the tasks table and make sure that status of that record is updated whenever the sub workflow completes. Then the query in the Embedded Merge Component might be something like this: select count(*) from MyTasksTable where ParentTrackingID = @ ParentTrackingID and Status = ‘Pending’
Would you like to reply?
Login or Register to post your comment.