Using the ServiceNow Session Management

JSessionID field can be used to execute the records in a single session.

About this task

Session Management is applicable for runtime operations only. If JSessionID value is null or expired, the Connector re-generates it implicitly, uses it in the execution of the activity and returns it in the response. This JSessionID can be used in other activities by providing the same value in the other activity. If the JSessionID is idle for 5 min it expires and user can provide the value as null and connector re-generates it.

Procedure

  1. Right click the Orchestrations section and select new orchestration.
  2. Drag the newly created ServiceNow endpoint to the orchestration and select any activity.
  3. Double click the activity added to the orchestration.
  4. In the Checklist, click Configure.
  5. Click Browseand use the Project Explorer dialog box to select the relevant ServiceNow table.
  6. Click the Map Inputs in the Checklist. The XML Schemas generated for the selected activity are displayed.
  7. Create a map between the orchestration variables and the input parameter of the activity.
  8. To reuse the session, provide valid session information in JSessionID Field. If the value is not available the connector re-generates it and returns.
    Note: Values must be provided at run time for any mandatory elements of the input structure. A value can be provided by specifying a default value for element or by linking the element with an input node.
  9. Select the Map Outputs in the Checklist. The XML Schema generated to hold the response of the activity is displayed as nodes under the response output parameter in the From Activity panel.
  10. Create a map between the output parameters and orchestration variables.

Results

You have configured the ServiceNow activity. If Session ID present in JSessionID is valid then the same should be displayed in Map Outputs as JSessionID. This value can be stored in a Variable and can be used in execution of further operations. If the JSessionID field value is invalid or expired then new session ID gets created which is then implicitly used in the execution of an activity. This new value is then displayed in Map Outputs as JSessionID.
Note:

You can add more than one object as input to this activity. To add more than one object as input, right click the object in the To Activity pane of Map Inputs, and select Expand Occurrences. Only multiple objects of the same type is supported.




Feedback | Notices


Timestamp icon Last updated: Monday, 6 March 2017


http://pic.dhe.ibm.com/infocenter/wci/v7r0m0/topic/com.ibm.wci.doc/Service_Now_using_the_servicenow_session_management.html