I've got a web project and I've enabled two workflows for it. The details are slightly different but we can model the problem as:
1. On a given Web Project I have one "Web Site Submission" workflow WSS and a custom workflow CWF. The two workflows have different regular expressions (RE1 and RE2) in the "Filename pattern match".
2. When the modified files all match RE1 I want it to use WSS so it's reviewed.
3. When the modified files all match RE2 I want it to use CWF (it's not reviewed and it's automatically deployed).
4. When some modified files match RE1 and others match RE2 I would like the corresponding files to go to the correct workflow (RE1->WSS, RE2->CWF).
Currently what happens is that I get a submit dialog that shows both WSS and WSS workflows, I can select one or the other and all the modified files go to the selected workflow.
What's a good way to get the behavior described above? Is there some bean I could customize (runs before submit-dialog.jsp is called) that could clean up the list of files and the available workflows so that submit-dialog would show only one workflow and the matching files (probably with a warning that there are still other files to be deployed by another workflow so the user would know to run submit again)?
Or would I have just one workflow and have the workflow detect that certain files need review and the running workflow forks off a second workflow in parallel for the files to be reviewed? If that's the right way to do it, how would it be done?