A4J (Automation for Jira) rule does not assign any values to the Asset object custom field when triggered by the schedule

Still need help?

The Atlassian Community is here for you.

Ask the community

Platform Notice: Cloud Only - This article only applies to Atlassian products on the cloud platform.

For Jira DC, the Branch on AQL is still not available: JIRAAUTOSERVER-544 - Insights Automation: Automation "Branch Rule" for Insight IQL results - Jira DC

Summary

A4J (Automation for Jira) rule does not assign any values to the Assets object field when triggered by the schedule.

Environment

Jira Service Management Cloud 

Diagnosis

When A4J is triggered by the schedule and creates a new issue, it cannot assign values to the Asset objects.
See the example below:

The Asset custom field in this example is an Asset object custom field.

The new issue is created with an empty Asset custom field.

Cause

The trigger for the A4J rule to assign value to the Assets object custom fields needs to be an issue or an object. The scheduled trigger does not meet these criteria.

Solution

Create a Global A4J rule with a Branch on AQL and trigger issue creation inside the branch. 

See the example below:


  • The {{object}} refers to the current object Asset object of the AQL branch.
  • If the AQL query returns several records, the rule will create several issues.

Please note that adding the Assets Object to its field at issue creation may not function due to a know Bug. See JSDCLOUD-10421 for a proposed workaround with the Edit Issue action.


After the Global A4J rule execution, the new issue is created with the filled Asset custom field.



Last modified on Oct 26, 2022

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.