-
Bug
-
Resolution: Fixed
-
Medium
-
3.5.3, 3.6, 5.1.5, 6.1
-
3.05
-
3
-
If I have a workflow Validator set on a transition, and then try to bulk-transition issues through this transition, and if the validator fails, then:
- The issue is not transitioned
- No indication of this is given to the user
- An error from the validator is logged
For instance, given the following validator on the standard workflow:
<action id="005" view="resolveissue" name="Resolve Issue"> .... <validators> <validator type="class"> <arg name="class.name">com.atlassian.jira.workflow.validator.TestValidator</arg> </validator> </validators>
package com.atlassian.jira.workflow.validator; import com.opensymphony.workflow.Validator; import com.opensymphony.workflow.InvalidInputException; import com.opensymphony.workflow.WorkflowException; import com.opensymphony.module.propertyset.PropertySet; import java.util.Map; public class TestValidator implements Validator { public void validate(Map map, Map map1, PropertySet propertySet) throws InvalidInputException, WorkflowException { System.out.println("Validator called"); throw new InvalidInputException("TestValidator failed"); } }
when bulk resolving an open issue, the following appears in the logs:
Validator called 2006-04-06 18:47:51,493 ERROR [atlassian.jira.workflow.SimpleWorkflowManager] An exception occurred [InvalidInputException: [Error map: [{}]] [Error list: [[TestValidator failed]]] at com.atlassian.jira.workflow.validator.TestValidator.validate(TestValidator.java:17) at com.opensymphony.workflow.AbstractWorkflow.verifyInputs(AbstractWorkflow.java:985) at com.opensymphony.workflow.AbstractWorkflow.transitionWorkflow(AbstractWorkflow.java:1198) at com.opensymphony.workflow.AbstractWorkflow.doAction(AbstractWorkflow.java:533) at com.atlassian.jira.workflow.SimpleWorkflowManager.doWorkflowAction(SimpleWorkflowManager.java:228) at com.atlassian.jira.bulkedit.operation.BulkWorkflowTransitionOperation.perform(BulkWorkflowTransitionOperation.java:103) at com.atlassian.jira.web.action.issue.bulkedit.BulkWorkflowTransition.doPerform(BulkWorkflowTransition.java:187) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
and the issue is not transitioned.
- is related to
-
JRASERVER-9931 Failing validators during bulk transition cause index to be updated incorrectly
- Closed
- relates to
-
JRASERVER-5783 Make field required only for one state transition
- Closed
-
JRASERVER-65813 Make field required only for one state transition
- Gathering Interest
- mentioned in
-
Page Loading...