Here's a bit of a compound conundrum I'm trying to resolve.
User Stories have a user story workflow.
The Engineering Sub-Task type has an engineering sub-task workflow.
The QA Sub-Task type has a qa sub-task workflow.
I have the following compound criteria to meet:
I've seen a few workflow plugins that allow transition of the parent if *all* sub-task types are set to a particular status or resolution. That would violate #2, however.
Are there any plugins that allow you to segregate sub-task types for different transition thresholds?
I've been searching and thus far I haven't found any.
From a logic perspective it could work like this:
NOTE: There is no allowed transition of the story from Step 2 to Step 4. That is handled at the User Story level.
Does this make sense? Any plugins you can think of to assist in this?
It seems JIRA Misc Workflow Extensions and JIRA Workflow Toolbox thus far have come closest, but no cigar on the last bits of these requirements.
Any help is greatly appreciated.
Sincerely,
Malik Graves-Pryor
Hi Malik,
Your requirements can be implemented in JIRA Workflow Toolbox using two features of this plugin:
Now I explain in detail how to do it. I'm considering that "Done" is a status in subtasks workflows, but if it were a Resolution value it wouldn't be a problem.
1.- Post-function "Copy parsed text to a field" in transition "Start Progress" in "Engineering Sub-Task" and "QA Sub-Task" workflows
This post-function will auto-transition parent issue to "Step 2" when any of the subtasks are moved to status "In Progress".
Use the configuration shown in the screenshot. Notice that "Status of Step 2" must be replaced with the name of the status associated with Step 2:
2.- Post-function "Copy parsed text to a field" in transition to status "Done" in "Engineering Sub-Task" workflow
This post-function will auto-transition parent issue to "Step 3" when the last Engineering Subtask is moved to status "Done". This post-function work as a team with validator "Validation on subtask" in transition "From Step 2 to Step 3" in Story workflow.
Use the configuration shown in the screenshot. Notice that "Status of Step 3" must be replaced with the name of the status associated with Step 3:
3.- Validator "Validation on subtasks" in transition "From Step 2 to Step 3" in Story workflow:
This validator will prevent execution of transition from Step 2 to Step 3 unless every Engineering Subtask is in status "Done":
4.- Validator "Validation on subtasks" in transition "From Step 3 to Step 4" in Story workflow:
This validator will prevent execution of transition from Step 3 to Step 4 unless every Engineering Subtask and QA Subtask is in status "Done":
Regards,
Fidel.
This is exceedingly comprehensive, far outstripping what I was expecting.
I salute you sir!
Sincerely,
Malik Graves-Pryor
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Fidel,
I found one issue with this. The steps you've outlined function if the user story transition requiring "Engineering Sub-Tasks" to be complete (Step 3) is not an auto transition.
The validation will fail as expected, and once all "Engineering Sub-Tasks" are done, then and only then can the workflow step be executed. But the execution has to be done manually. It won't automatically transition.
Does this make sense?
Sincerely,
Malik Graves-Pryor
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I've finally reduced the issue down to its component parts.
The story validation functions as expected if there are only "Engineering Sub-Tasks". However, as soon as I add another type of Sub-Task to the user story, the validation function in the user story transition ceases to work.
I followed the instructions above. Any ideas?
Sincerely,
Malik Graves-Pryor
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Malik,
I have implemented the whole configuration in a JIRA 6.2 instance with Jira Workflow Toolbox 2.1.14 and it's working perfectly.
Did you left parameter "Allow unselected issue types" unchecked in step 3? This parameter must be checked in both steps 3 and 4.
Regards,
Fidel
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Fidel,
Yes, I followed your instructions and triple checked to make sure I did everything as stated.
That said, I am running 2.1.14 on JIRA 6.1.17. I've requested devops to upgrade our JIRA instance to 6.2. It's possible that might be the issue?
Sincerely,
Malik Graves-Pryor
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
One last bit, I checked Step 3 and 4. They are identical except Step 3 only has Engineering Sub-Tasks checked. Step 4 has Engineering Sub-Tasks and QA Sub-Tasks checked.
Everything else is identical.
Please see the attached screenshots from Step 3 and 4 in the user story workflow, and the post-function in the sub-task workflow, in order
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Malik,
Did you try to execute manually transition "Engineering Peer Review" in "Story" workflow? It should allow execution only when all "Engineering Sub-Task" are in status "Done", regardless of the status of any other subtask types (QA Sub-Task or any other issue type) it might have.
It should behave like I described. In case it doesn't, please describe the failling issue: issue type, status, and subtasks issue types and statuses.
On the other hand, it's preferred to execute post-function "Copy parsed text to a field" before system's default post-functions, in your case move it to first position in execution order.
I don't think this problem is caused by the JIRA version your are using, since the plugin is fully compatible with JIRA 6.x
Regards,
Fidel
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Fidel,
I tried manually executing the transition and it gives me the validation error even though all Engineering Sub-Tasks are in "Done" status. There are QA Sub-Tasks in "To Do" status at the time.
If I delete the QA Sub-Tasks and try to transition the story again, it works without problem.
The story is "In Progress", the Sub-Tasks are Engineering Sub-Task and QA Sub-Task, and their respective statuses are "Done" and "To Do".
That said, I changed the execution of the post-function so that it goes first. It didn't make a difference unfortunately. We also did the upgrade and nothing changed either.
Is there anything else you'd like to see in my installation/configuration?
Your help is definitely appreciated in getting this functioning.
Sincerely,
Malik Graves-Pryor
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Malik,
I can't figure out what it's happening. "Validation on linked issues" has no reported issues and the same configuration is working perfectly in my jira instance.
Please, try moving "QA Sub-tasks" to "Done" status, i.e., all "QA Subtaks" and "Engineering Sub-tasks" in "Done" status, and let me know if you can execute transition in "Story" workflow from "In Progress" to "Engineering Peer Review".
BTW, which version of the plugin are you using?
Anyway, I'm available for a Skype meeting to discuss the issue.
Regards,
Fidel.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Fidel,
I'm definitely able to execute the transition of the story from "In Progress" to "Engineering Peer Review" if all QA Sub-Tasks are "Done" along with Engineering Sub-Tasks, or if there are no QA Sub-Tasks.
That saiid, I'm using version 2.1.14.
I'm on Skype, malikgp. When would you like to chat? Your support is greatly appreciated.
Sincerely,
Malik Graves-Pryor
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Please, try exchanging configurations in both validations, i.e., the one with both isssue types checked ("Engineering Sub-tasks" and "QA Sub-tasks") now will get only "Engineering Sub-tasks", and viceversa.
Perhaps, we are having some kind of misunderstanding.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Fidel,
I gave that a whirl and no dice. Would it be possible for me to share my screen with you so can you see what I've got in place?
Sincerely,
Malik Graves-Pryor
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Malik,
Definitely you found a bug in "Validator on subtasks". I have released version 2.1.15_beta_1 fixing the problem. "Condition on subtasks" was also affected by the problem.
This version only differs from 2.1.14 in this fix, so you can use it in production environment securely.
Regards,
Fidel.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Fidel,
After extensive testing I can confirm that the 2.1.15_beta_1 version has resolved the issue. The workflow is working as expected.
Thank you so much!
Sincerely,
Malik Graves-Pryor
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
What happens after a transition is complete and a subtask is reopened? Or if you want to return the parent task to the previous status?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Chris, I have answered to here: https://groups.google.com/d/msg/jira-workflow-toolbox-plugin/DZZ5aHeCiVU/x1Mgw7u5CQAJ Regards, Fidel
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Malik,
I know it has been 3 years and I'm sorry for waking up this up ....
I have been trying all day to achieve this with JMWE and since this post is already indexed by google I wanted to link the solution from here for people looking for help.
https://github.com/weboholic/userscripts/blob/master/transition.parent.onsubtask.conditional.groovy
Cheers,
Nikola
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hey guys,
first of all, thanks a lot for that topic and the linked solution.
I changed the linked solution as we don't have any specific subtask-types.
Collection subTasks = parentIssueObject.getSubTaskObjects()
def condition = true
subTasks.each{subtask ->
if (subtask.statusObject.name != "done") {
condition = false
}
}
return condition
I have tested the script and it is working fine in the JMWE Groovy Script Tester. But the post function is not updating transition the parent issue.
Any ideas?
Cheers,
Simon
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I got a response from support. The post-function had to be moved to the end of the list of post functions so that the transition of the subtask is executed before the post-function is executed for the parent issue
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I tried this solution, but it's moving my story when the first sub-task is moved, but I don't want it to move until the last one has moved to Done. Any idea what's not working?
https://github.com/weboholic/userscripts/blob/master/transition.parent.onsubtask.conditional.groovy
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You can indeed achieve the conditional automatic parent transitions you're mentioning using JIRA Misc Workflow Extensions. You can use the "Transition Parent Issue" post-function, using its conditional execution parameter (a Groovy formula).
However, the plugin currently doesn't include a scriptable Condition, although that is certainly a good idea for an enhancement, which you can request at https://innovalog.atlassian.net/secure/CreateIssue.jspa?pid=10793&issuetype=2
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi David,
I tried to create an issue but it says I do not have permission to do so in that project. Any ideas?
Sincerely,
Malik Graves-Pryor
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Malik,
this is caused by a bug in the latest JIRA OnDemand version that was deployed by Atlassian a few days ago. I have reported the issue to Atlassian and am waiting for a fix.
In the interim, I believe I have fixed your particular access rights so you should now be able to create issues.
Thanks for reporting this,
David.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi again Malik,
Atlassian has fixed the issues we were facing on https://innovalog.atlassian.net
All new and existing users should have regained access to issue creation, as well as the Confuence pages.
David.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks David, I'll file a request for this feature
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Try Jjupin. You can put any conditions you want. An example for subtasks is here: http://confluence.kepler-rominfo.com/display/TR/Autotransitioning+subtasks
Of course, you must modify to match your conditions and apply the stuff on parent, not on the subtasks, but you will get the idea.
You can also try ScriptRunner (it's free) if you like groovy and want to deal with Jira internals yourself.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Radu,
I had not looked at ScriptRunner before, but I will definitely do now. It looks quite powerful!
Sincerely,
Malik Graves-Pryor
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.