-
Bug
-
Resolution: Duplicate
-
Low (View bug fix roadmap)
-
None
-
6.4.14, 7.6.0
-
None
-
6.04
-
2
-
Severity 2 - Major
-
Summary
Jira default workflow generates corrupted descriptor for Software Project.
Environment
- JIRA Software 7.6.0-EAP01
- JIRA Agile 6.7.16
Steps to Reproduce
Expected Results
Transitions are correctly rendered.
Actual Results
Transitions get corrupted. However, no error or warning occur. This corruption also happens to copied workflow from the original generated one.
Notes
Descriptor is formatted by valid XML. However, it contains redundant line break in XML attributes like:
<arg name="class.name">com.atlassian.jira.workflow.function.event.FireIssueEventFunction </arg>
E.g. Here's a whole record: 1512632770_workflow.csv from
select * from jiraworkflows where workflowname id = 10200
It's still not sure which is the problem injecting line break itself or parser unavailability for a line break.
Workaround
For Jira administrator:
- If you need to edit the generated workflow, create your own workflow instead of editing or copying the generated workflow
For system administrator:
- Stop JIRA
- Make sure to backup data just in case
- Fix the descriptor
- For instance:
$ W_ID="10200" $ psql ... -d __DB_NAME__ -c "Copy (select descriptor from jiraworkflows where id = ${W_ID}) To STDOUT;" > descriptor_${W_ID}.xml # Edit the xml file (Remove '\n' and the redundant line breaks) $ psql ... -c "update jiraworkflows set descriptor = '$(cat descriptor_${W_ID}.xml)' where id = ${W_ID}" __DB_NAME__
- For instance:
- Start JIRA
- Verify the affected workflow is fixed (Discard the draft workflow if exists)
- duplicates
-
JSWSERVER-11547 JIRA Agile Simplified Workflow - Post Functions displayed incorrectly
-
- Closed
-
- is related to
-
JRASERVER-23071 Line breaks in workflow XML result in transition crashes
-
- Closed
-
[JRASERVER-66448] XML descriptor gets broken with Software Project
Minimum Version | New: 6.04 |
Workflow | Original: JAC Bug Workflow v2 [ 2848632 ] | New: JAC Bug Workflow v3 [ 2930083 ] |
Status | Original: Resolved [ 5 ] | New: Closed [ 6 ] |
Symptom Severity | Original: Major [ 14431 ] | New: Severity 2 - Major [ 15831 ] |
Workflow | Original: JIRA Bug Workflow w Kanban v7 - Restricted [ 2584822 ] | New: JAC Bug Workflow v2 [ 2848632 ] |
Status | Original: Closed [ 6 ] | New: Resolved [ 5 ] |
Workflow | Original: JIRA Bug Workflow w Kanban v6 - Restricted [ 2488163 ] | New: JIRA Bug Workflow w Kanban v7 - Restricted [ 2584822 ] |
Resolution | New: Duplicate [ 3 ] | |
Status | Original: Open [ 1 ] | New: Closed [ 6 ] |
Link |
New:
This issue duplicates |
Support reference count | New: 2 |
Description |
Original:
h3. Summary
Jira default workflow generates corrupted descriptor for Software Project. h3. Environment * JIRA Software 7.6.0-EAP01 * JIRA Agile 6.7.16 h3. Steps to Reproduce # Create a Software Project (Any of Scrum, Kanban, Basic) # Edit its workflow and select Post Functions !Screenshot 2017-12-07 18.10.18.png|thumbnail! h3. Expected Results Transitions are correctly rendered. h3. Actual Results Transitions get corrupted. However, no error or warning occur. This corruption also happens to copied workflow from the original generated one. h3. Notes Descriptor is formatted by valid XML. However, it contains redundant line break in XML attributes like: {code:none} <arg name="class.name">com.atlassian.jira.workflow.function.event.FireIssueEventFunction </arg> {code} E.g. Here's a whole record: [^1512632770_workflow.csv] from {code:none} select * from jiraworkflows where workflowname id = 10200 {code} It's still not sure which is the problem injecting line break itself or parser unavailability for a line break. h3. Workaround For Jira administrator: * If you need to edit the generated workflow, create your own workflow instead of editing or copying the generated workflow For system administrator: # Make sure to [export backup|https://confluence.atlassian.com/adminjiraserver/backing-up-data-938847673.html] in case you lost the data # [Stop JIRA|https://confluence.atlassian.com/adminjiraserver/start-and-stop-jira-applications-938847802.html] # Fix the descriptor ** For instance: {code:none} $ W_ID="10200" $ psql ... -d __DB_NAME__ -c "Copy (select descriptor from jiraworkflows where id = ${W_ID}) To STDOUT;" > descriptor_${W_ID}.xml # Edit the xml file (Remove '\n' and the redundant line breaks) $ psql ... -c "update jiraworkflows set descriptor = '$(cat descriptor_${W_ID}.xml)' where id = ${W_ID}" __DB_NAME__ {code} # [Start JIRA|https://confluence.atlassian.com/adminjiraserver/start-and-stop-jira-applications-938847802.html] # Verify the affected workflow is fixed (Discard the draft workflow if exists) |
New:
h3. Summary
Jira default workflow generates corrupted descriptor for Software Project. h3. Environment * JIRA Software 7.6.0-EAP01 * JIRA Agile 6.7.16 h3. Steps to Reproduce # Create a Software Project (Any of Scrum, Kanban, Basic) # Edit its workflow and select Post Functions !Screenshot 2017-12-07 18.10.18.png|thumbnail! h3. Expected Results Transitions are correctly rendered. h3. Actual Results Transitions get corrupted. However, no error or warning occur. This corruption also happens to copied workflow from the original generated one. h3. Notes Descriptor is formatted by valid XML. However, it contains redundant line break in XML attributes like: {code:none} <arg name="class.name">com.atlassian.jira.workflow.function.event.FireIssueEventFunction </arg> {code} E.g. Here's a whole record: [^1512632770_workflow.csv] from {code:none} select * from jiraworkflows where workflowname id = 10200 {code} It's still not sure which is the problem injecting line break itself or parser unavailability for a line break. h3. Workaround For Jira administrator: * If you need to edit the generated workflow, create your own workflow instead of editing or copying the generated workflow For system administrator: # [Stop JIRA|https://confluence.atlassian.com/adminjiraserver/start-and-stop-jira-applications-938847802.html] # Make sure to [backup data|https://confluence.atlassian.com/adminjiraserver/backing-up-data-938847673.html] just in case # Fix the descriptor ** For instance: {code:none} $ W_ID="10200" $ psql ... -d __DB_NAME__ -c "Copy (select descriptor from jiraworkflows where id = ${W_ID}) To STDOUT;" > descriptor_${W_ID}.xml # Edit the xml file (Remove '\n' and the redundant line breaks) $ psql ... -c "update jiraworkflows set descriptor = '$(cat descriptor_${W_ID}.xml)' where id = ${W_ID}" __DB_NAME__ {code} # [Start JIRA|https://confluence.atlassian.com/adminjiraserver/start-and-stop-jira-applications-938847802.html] # Verify the affected workflow is fixed (Discard the draft workflow if exists) |
I find 2 cases.
Simple case is when creating Kanban project.
And another one is converting any projects to Kanban project. In this case, Jira workflow engine simplifies its workflow and this simplification process inserts line break into XML attribution definition, then write JIRAWORKFLOWS table.
N.Chihara