Jira

Use the IBM® App Connect Enterprise Toolkit to configure message flow nodes that are converted from the IBM App Connect Professional Jira activities.

About this task

When you import an orchestration that contains Jira activities, the conversion utility creates a message flow with the Jira Request node. See Table 1, for information on which nodes are used for each of the activities.

Table 1. IBM App Connect Professional Jira activities and the corresponding IBM App Connect Enterprise message flow nodes
IBM App Connect Professional activity IBM App Connect Enterprise node
Create objects

Jira Request node

Update objects

Jira Request node

Retrieve objects

Jira Request node

Retrieve all objects

Jira Request node

Delete objects

Jira Request node

The Jira Request node is used in IBM App Connect Enterprise for all the activities of Jira connector in IBM App Connect Professional.

Connecting to Jira

Procedure

  1. Select the Jira Request node in the message flow.
  2. In the Properties tab, click Launch connector discovery to open the wizard.
    App Connect Enterprise toolkit showing interface for specifying Jira request node properties Interface for specifying policy project
  3. Select the Jira policy project from the drop-down menu or create a new one. The Jira connection information is then saved in a policy.
    Interface for naming policy project with input box completed
  4. Click Test Vault Access to check whether vault credentials are correct. If not, type the credentials. The vault is then used to store the Jira connection credentials. The process of connecting to Jira and discovering information from it causes your Jira credentials to be saved in the vault.
  5. Click Launch discovery to open a new configure connector node window.
    Interface showing policy project with vault location and key fields completed

    If you previously connected to Jira, then a list of those connections would be displayed. If you did not previously connect to Jira, then the status of the Jira connector is shown as Not connected.

  6. If you did not previously connect to a Jira system, follow these steps:
    1. Expand the Not connected panel, expand any section (for example, Issues) and choose any action (for example, Create issue).
      Expanded list showing all actions relating to Issues
    2. The list of objects and actions is replaced with a Connect button. Click Connect.
      Connector Discovery window
  7. Complete the required connection information for the Jira account by providing the Jira host and port, username, and password from the endpoint section of the generated document.
    Interface for specifying endpoint details
  8. Click Connect to verify the connection. Then close the window.

What to do next

Note: For all actions with Jira, apply the following steps, then continue on to the steps specific to each activity:
  • Select the node in the message flow.
  • In the Properties tab, click Launch connector discovery to open the wizard.
  • Select a Jira policy project from the drop-down menu or create a new one.
  • Click Test vault access to check whether vault credentials are correct. If not, type the credentials of the vault you are using.
  • Click Launch discovery. A new configure connector node window then opens.
  • Expand the Jira section and select the Jira account that you want to connect to.

Jira Request node for create objects activity

Procedure

  1. Expand Issues and select Create issue.
  2. Expand Controls and complete How do you want to populate the target fields in Jira.
  3. Option 1:
    1. Specify data for all required target fields.
    2. You can also provide data for optional fields that you intend to use in the target application. You can either enter the values directly into the fields or map them from the output of previous nodes.
    3. If a default value is available, refer to the generated document for it. Otherwise, use the output from previous nodes.
    4. For guidance on how to map values from previous nodes, refer to the How to Add the Previous Node's Output section in the documentation.
  4. Option 2: Use the input message unchanged.
  5. Click Save and close the window.
    Screenshot of connector discovery window

Jira Request node for update objects activity

Procedure

  1. Expand Issues and select Update issue.
  2. Expand Controls and complete How do you want to populate the target fields in Jira.
  3. Option 1:
    1. Specify data for all required target fields.
    2. You can also provide data for optional fields that you intend to use in the target application. You can either enter the values directly into the fields or map them from the output of previous nodes.
    3. If a default value is available, refer to the generated document for it. Otherwise, use the output from previous nodes.
    4. For guidance on how to map values from previous nodes, refer to the How to Add the Previous Node's Output section in the documentation.
  4. Option 2: Use the input message unchanged.
  5. Click Save and close the window.
    Screenshot of connector discovery window

Jira Request node for retrieve objects activity

Procedure

  1. Expand Issues and select Retrieve issue.
  2. Add the conditions, either by typing the values in the fields, or mapping them from the output of previous nodes.
    1. If a default value is available, refer to the generated document for it.
    2. Otherwise, use the output from previous nodes.
    3. For guidance on how to map values from previous nodes, refer to the How to Add the Previous Node's Output section in the documentation.
      Screenshot of connector discovery window
      Note: In IBM App Connect Professional, the ID field is typically used when retrieving objects, so make sure to add the condition by using the appropriate ID field.

Jira Request node for retrieve all objects activity

Procedure

  1. Expand Issues comments and select Retrieve all issue comments.
  2. Add the conditions, either by typing the values in the fields, or mapping them from the output of previous nodes.
    1. If a default value is available, refer to the generated document for it.
    2. Otherwise, use the output from previous nodes.
    3. For guidance on how to map values from previous nodes, refer to the How to Add the Previous Node's Output section in the documentation.
      Screenshot of connector discovery window

Jira Request node for delete objects activity

Procedure

  1. Expand Issues and select Delete issue.
  2. Define the mappings either by typing the values in the fields, or mapping them from the output of previous nodes.
    1. If a default value is available, refer to the generated document for it.
    2. Otherwise, use the output from previous nodes.
    3. For guidance on how to map values from previous nodes, refer to the How to Add the Previous Node's Output section in the documentation.
      Screenshot of connector discovery window

Adding the previous node's output

About this task

Subflow with the Compute node can be used to capture the output from other nodes.

Procedure

  1. Right click the application that you created > New > Select subflow.
  2. Give a name to the subflow and click Finish.
    Interface for creating a new Subflow
  3. Add a Compute node between the input and output nodes as shown in the screenshot.
    Screenshot showing example flow with input node first, then compute node, then output node at the end
  4. In Properties, go to the basic tab, and set the compute mode to All.
    Interface for specifying compute node properties
  5. In the Compute node, copy the following ESQL code to the compute node to save the outputs from each node that points to the subflow to the environment tree:
    DECLARE I SHARED INTEGER 1;
    CREATE COMPUTE MODULE SFSubflow_Compute
    	CREATE FUNCTION Main() RETURNS BOOLEAN
    	BEGIN
    		-- CALL CopyMessageHeaders();
    		-- CALL CopyEntireMessage();
    		SET Environment.Node[I] = InputBody;
    		SET I =I+1;
    		RETURN TRUE;
    	END;
    
    	CREATE PROCEDURE CopyMessageHeaders() BEGIN
    		DECLARE I INTEGER 1;
    		DECLARE J INTEGER;
    		SET J = CARDINALITY(InputRoot.*[]);
    		WHILE I < J DO
    			SET OutputRoot.*[I] = InputRoot.*[I];
    			SET I = I + 1;
    		END WHILE;
    	END;
    
    	CREATE PROCEDURE CopyEntireMessage() BEGIN
    		SET OutputRoot = InputRoot;
    	END;
    END MODULE;
  6. In your message flow, point the out terminal from each of the nodes to the subflow as shown in the screenshot. Don't connect the output terminal of the subflow to any nodes.
    App Connect Enterprise toolkit showing connected nodes
  7. To to use the output from other nodes in the node, add the environment in the request. In Properties, go to the request tab, and click Add. The Add map inputs entry window opens, set the input name to Environment from the drop-down list and click OK.
    Interface for entering map inputs. The name field is completed Interface for entering map inputs. InputLocalEnvironment is highlighted
  8. In the discovery window, click Insert a mapping icon, select the environment from map inputs/environment.
    Interface for entering available mappings with a drop-down list of options to choose from
  9. Click Environment and select Edit expression.
    Screenshot showing list of options of actions. Edit expression is highlighted
  10. Give the input as in the screenshot. Indexing starts from zero and it is mapped in such a way that first node output is stored in zeroth index and so on.
    Screenshot showing input for Record IDs and Merge IDs fields completed