0 Replies Latest reply on May 21, 2020 1:21 PM by Keshav Gupta

    Please help me on building sample workflow for sending incident request to servicenow from BMC AO workflow using Snow Actor adapter

    Keshav Gupta
      Share This:

      Hi Folks,

       

      Am new to BMC AO, am trying to fetch some records from the db table and wanted to assign those output values in the incident creation to personal developer servicenow instance.

      Currently I created a attached workflow and am unable to assign values correctly in the XML input. Please find the xml sample am using :

      I dont know how to put the Node name value which i selected from the table to cmdb_ci value.

       

      Can any one please provide the sample xml for sending incident request to servicenow with this situation. Please help on this. It will be very helpful.

       

       

       

      <items>

      <item>

      <caller-id>System Administrator</caller-id>

      <location>Americas</location>

      <opened-by>System Administrator</opened-by>

      <category>Software</category>

      <assignment-group>Service Desk</assignment-group>

      <Impact>1 - High</Impact>

      <Urgency>1 - High</Urgency>

      <cmdb_ci>ctx Node </cmdb_ci> (Here local context name am using)

      <short_description>Testing</short_description>

      </item>

      </items>

       

       

       

                         DEBUG - Preparing to test the process......... DEBUG - Starting Local Peers on the grid........ DEBUG - Started all local peers. DEBUG - --------------------------------------------------- DEBUG - -- About to Start WorkFlow Testing DEBUG - --------------------------------------------------- DEBUG - Process Details: DEBUG - Grid Name: NAO DEBUG - Module Name: SNOW_Testing DEBUG - Process ID: :SNOW_Testing:Create Incident DEBUG - Launch Requested 22 May 2020 05:52:11,640 [Current Time=Fri May 22 05:52:11 GMT+12:00 2020] [Process Name=:SNOW_Testing:Create Incident] [Root Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083531609] [Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083531609] [ProcessStart=The process started. It is triggered by the scheduler.] 

      22 May 2020 05:52:11,703 [Current Time=Fri May 22 05:52:11 GMT+12:00 2020] [Process Name=:SNOW_Testing:Select] [Root Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083531609] [Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083531609/:SNOW_Testing:Create Incident:start:call-process[1]] [Parent Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083531609] [TEXT=Adapter request] [adapter request= <request-data> <sqlAdapterRequest> <action>select IDENTIFIER, NODE, NODEALIAS, AGENT, ALERTGROUP, ALERTKEY, SUMMARY, FIRSTOCCURRENCE, LASTOCCURRENCE, ORIGINALSEVERITY, SERVERNAME, SERVERSERIAL, ACSCUSTOMER, ACSSMAKETICKET from REPORTER_ALERT_TSO where NODE = 'odpemsda12x11'</action> </sqlAdapterRequest> </request-data>] 
      22 May 2020 05:52:12,203 [Current Time=Fri May 22 05:52:12 GMT+12:00 2020] [Process Name=:SNOW_Testing:Select] [Root Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083531609] [Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083531609/:SNOW_Testing:Create Incident:start:call-process[1]] [Parent Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083531609] [TEXT=Adapter response] [adapter response= <sqlAdapterResponse> <row> <column name="IDENTIFIER" label="IDENTIFIER">odpemsda12x11-SEVONE-TRAP-MIB-Tier 2 - 15 Min-SNMP Poller  availability</column> <column name="NODE" label="NODE">odpemsda12x11</column> <column name="NODEALIAS" label="NODEALIAS">10.3.88.153</column> <column name="AGENT" label="AGENT">SEVONE-TRAP-MIB</column> <column name="ALERTGROUP" label="ALERTGROUP">Tier 2 - 15 Min</column> <column name="ALERTKEY" label="ALERTKEY">SNMP Poller  availability</column> <column name="SUMMARY" label="SUMMARY">Threshold triggered -- Node_Down: emsda12-x11 - SNMP is not available BY ZZZZZ</column> <column name="FIRSTOCCURRENCE" label="FIRSTOCCURRENCE">05/16/2020 18:18:32</column> <column name="LASTOCCURRENCE" label="LASTOCCURRENCE">05/18/2020 18:18:32</column> <column name="ORIGINALSEVERITY" label="ORIGINALSEVERITY">2</column> <column name="SERVERNAME" label="SERVERNAME">odpemsda12x11</column> <column name="SERVERSERIAL" label="SERVERSERIAL">12345678</column> <column name="ACSCUSTOMER" label="ACSCUSTOMER">XYZ</column> <column name="ACSSMAKETICKET" label="ACSSMAKETICKET">NULL</column> </row> <metadata> <queryExecuted>select IDENTIFIER, NODE, NODEALIAS, AGENT, ALERTGROUP, ALERTKEY, SUMMARY, FIRSTOCCURRENCE, LASTOCCURRENCE, ORIGINALSEVERITY, SERVERNAME, SERVERSERIAL, ACSCUSTOMER, ACSSMAKETICKET from REPORTER_ALERT_TSO where NODE = 'odpemsda12x11'</queryExecuted> <execution-milliseconds>13</execution-milliseconds> <responseRowCount>1</responseRowCount> <responseColumnCount>14</responseColumnCount> <status>success</status> </metadata> </sqlAdapterResponse>] 

      22 May 2020 05:52:12,203 [Current Time=Fri May 22 05:52:12 GMT+12:00 2020] [Process Name=:SNOW_Testing:Select] [Root Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083531609] [Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083531609/:SNOW_Testing:Create Incident:start:call-process[1]] [Parent Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083531609] [ProcessTermination=The process terminated in the completed state. The process started at 22 May 2020 05:52:11,671, terminated at 22 May 2020 05:52:12,203, and the execution took 532 milliseconds.] 22 May 2020 05:52:12,203 [Current Time=Fri May 22 05:52:12 GMT+12:00 2020] [Process Name=:SNOW_Testing:Create Incident] [Root Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083531609] [Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083531609] [Error=An error occurred that triggered compensation:] [TEXT= Summary: An internal error occurred which prevented successful execution completion. ] 22 May 2020 05:52:12,203 [Current Time=Fri May 22 05:52:12 GMT+12:00 2020] [Process Name=:SNOW_Testing:Create Incident] [Root Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083531609] [Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083531609] [StackTrace= Stack Trace: procdef:SNOW_Testing:Create Incident:start:assign[1] ] 22 May 2020 05:52:12,218 [Current Time=Fri May 22 05:52:12 GMT+12:00 2020] [Process Name=:SNOW_Testing:Create Incident] [Root Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083531609] [Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083531609] [ProcessTermination=The process terminated in the compensated state. The process started at 22 May 2020 05:52:11,640, terminated at 22 May 2020 05:52:12,218, and the execution took 578 milliseconds.] 22 May 2020 05:56:30,718 Preparing to test the process......... 22 May 2020 05:56:30,718 Starting Local Peers on the grid........ 22 May 2020 05:56:30,734 Started all local peers. 22 May 2020 05:56:30,734 --------------------------------------------------- 22 May 2020 05:56:30,734 -- About to Start WorkFlow Testing 22 May 2020 05:56:30,734 --------------------------------------------------- 22 May 2020 05:56:30,734 Process Details: 22 May 2020 05:56:30,734 Grid Name: NAO 22 May 2020 05:56:30,734 Module Name: SNOW_Testing 22 May 2020 05:56:30,734 Process ID: :SNOW_Testing:Create Incident 22 May 2020 05:56:30,781 Launch Requested 22 May 2020 05:56:32,156 [Current Time=Fri May 22 05:56:32 GMT+12:00 2020] [Process Name=:SNOW_Testing:Create Incident] [Root Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083792140] [Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083792140] [ProcessStart=The process started. It is triggered by the scheduler.] 

      22 May 2020 05:56:32,218 [Current Time=Fri May 22 05:56:32 GMT+12:00 2020] [Process Name=:SNOW_Testing:Select] [Root Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083792140] [Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083792140/:SNOW_Testing:Create Incident:start:call-process[1]] [Parent Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083792140] [TEXT=Adapter request] [adapter request= <request-data> <sqlAdapterRequest> <action>select IDENTIFIER, NODE, NODEALIAS, AGENT, ALERTGROUP, ALERTKEY, SUMMARY, FIRSTOCCURRENCE, LASTOCCURRENCE, ORIGINALSEVERITY, SERVERNAME, SERVERSERIAL, ACSCUSTOMER, ACSSMAKETICKET from REPORTER_ALERT_TSO where NODE = 'odpemsda12x11'</action> </sqlAdapterRequest> </request-data>] 
      22 May 2020 05:56:32,718 [Current Time=Fri May 22 05:56:32 GMT+12:00 2020] [Process Name=:SNOW_Testing:Select] [Root Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083792140] [Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083792140/:SNOW_Testing:Create Incident:start:call-process[1]] [Parent Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083792140] [TEXT=Adapter response] [adapter response= <sqlAdapterResponse> <row> <column name="IDENTIFIER" label="IDENTIFIER">odpemsda12x11-SEVONE-TRAP-MIB-Tier 2 - 15 Min-SNMP Poller  availability</column> <column name="NODE" label="NODE">odpemsda12x11</column> <column name="NODEALIAS" label="NODEALIAS">10.3.88.153</column> <column name="AGENT" label="AGENT">SEVONE-TRAP-MIB</column> <column name="ALERTGROUP" label="ALERTGROUP">Tier 2 - 15 Min</column> <column name="ALERTKEY" label="ALERTKEY">SNMP Poller  availability</column> <column name="SUMMARY" label="SUMMARY">Threshold triggered -- Node_Down: emsda12-x11 - SNMP is not available BY ZZZZZ</column> <column name="FIRSTOCCURRENCE" label="FIRSTOCCURRENCE">05/16/2020 18:18:32</column> <column name="LASTOCCURRENCE" label="LASTOCCURRENCE">05/18/2020 18:18:32</column> <column name="ORIGINALSEVERITY" label="ORIGINALSEVERITY">2</column> <column name="SERVERNAME" label="SERVERNAME">odpemsda12x11</column> <column name="SERVERSERIAL" label="SERVERSERIAL">12345678</column> <column name="ACSCUSTOMER" label="ACSCUSTOMER">XYZ</column> <column name="ACSSMAKETICKET" label="ACSSMAKETICKET">NULL</column> </row> <metadata> <queryExecuted>select IDENTIFIER, NODE, NODEALIAS, AGENT, ALERTGROUP, ALERTKEY, SUMMARY, FIRSTOCCURRENCE, LASTOCCURRENCE, ORIGINALSEVERITY, SERVERNAME, SERVERSERIAL, ACSCUSTOMER, ACSSMAKETICKET from REPORTER_ALERT_TSO where NODE = 'odpemsda12x11'</queryExecuted> <execution-milliseconds>9</execution-milliseconds> <responseRowCount>1</responseRowCount> <responseColumnCount>14</responseColumnCount> <status>success</status> </metadata> </sqlAdapterResponse>] 

      22 May 2020 05:56:32,718 [Current Time=Fri May 22 05:56:32 GMT+12:00 2020] [Process Name=:SNOW_Testing:Select] [Root Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083792140] [Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083792140/:SNOW_Testing:Create Incident:start:call-process[1]] [Parent Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083792140] [ProcessTermination=The process terminated in the completed state. The process started at 22 May 2020 05:56:32,187, terminated at 22 May 2020 05:56:32,718, and the execution took 531 milliseconds.] 22 May 2020 05:56:32,718 [Current Time=Fri May 22 05:56:32 GMT+12:00 2020] [Process Name=:SNOW_Testing:Create Incident] [Root Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083792140] [Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083792140] [Error=An error occurred that triggered compensation:] [TEXT= Summary: An internal error occurred which prevented successful execution completion. ] 22 May 2020 05:56:32,718 [Current Time=Fri May 22 05:56:32 GMT+12:00 2020] [Process Name=:SNOW_Testing:Create Incident] [Root Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083792140] [Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083792140] [StackTrace= Stack Trace: procdef:SNOW_Testing:Create Incident:start:assign[1] ] 22 May 2020 05:56:32,718 [Current Time=Fri May 22 05:56:32 GMT+12:00 2020] [Process Name=:SNOW_Testing:Create Incident] [Root Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083792140] [Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590083792140] [ProcessTermination=The process terminated in the compensated state. The process started at 22 May 2020 05:56:32,156, terminated at 22 May 2020 05:56:32,718, and the execution took 562 milliseconds.] 22 May 2020 06:31:22,328 Preparing to test the process......... 22 May 2020 06:31:22,328 Starting Local Peers on the grid........ 22 May 2020 06:31:22,343 Started all local peers. 22 May 2020 06:31:22,343 --------------------------------------------------- 22 May 2020 06:31:22,343 -- About to Start WorkFlow Testing 22 May 2020 06:31:22,343 --------------------------------------------------- 22 May 2020 06:31:22,343 Process Details: 22 May 2020 06:31:22,343 Grid Name: NAO 22 May 2020 06:31:22,343 Module Name: SNOW_Testing 22 May 2020 06:31:22,343 Process ID: :SNOW_Testing:Create Incident 22 May 2020 06:31:22,406 Launch Requested 22 May 2020 06:31:23,734 [Current Time=Fri May 22 06:31:23 GMT+12:00 2020] [Process Name=:SNOW_Testing:Create Incident] [Root Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590085883703] [Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590085883703] [ProcessStart=The process started. It is triggered by the scheduler.] 

      22 May 2020 06:31:23,828 [Current Time=Fri May 22 06:31:23 GMT+12:00 2020] [Process Name=:SNOW_Testing:Select] [Root Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590085883703] [Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590085883703/:SNOW_Testing:Create Incident:start:call-process[1]] [Parent Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590085883703] [TEXT=Adapter request] [adapter request= <request-data> <sqlAdapterRequest> <action>select IDENTIFIER, NODE, NODEALIAS, AGENT, ALERTGROUP, ALERTKEY, SUMMARY, FIRSTOCCURRENCE, LASTOCCURRENCE, ORIGINALSEVERITY, SERVERNAME, SERVERSERIAL, ACSCUSTOMER, ACSSMAKETICKET from REPORTER_ALERT_TSO where NODE = 'odpemsda12x11'</action> </sqlAdapterRequest> </request-data>] 
      22 May 2020 06:31:24,328 [Current Time=Fri May 22 06:31:24 GMT+12:00 2020] [Process Name=:SNOW_Testing:Select] [Root Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590085883703] [Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590085883703/:SNOW_Testing:Create Incident:start:call-process[1]] [Parent Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590085883703] [TEXT=Adapter response] [adapter response= <sqlAdapterResponse> <row> <column name="IDENTIFIER" label="IDENTIFIER">odpemsda12x11-SEVONE-TRAP-MIB-Tier 2 - 15 Min-SNMP Poller  availability</column> <column name="NODE" label="NODE">odpemsda12x11</column> <column name="NODEALIAS" label="NODEALIAS">10.3.88.153</column> <column name="AGENT" label="AGENT">SEVONE-TRAP-MIB</column> <column name="ALERTGROUP" label="ALERTGROUP">Tier 2 - 15 Min</column> <column name="ALERTKEY" label="ALERTKEY">SNMP Poller  availability</column> <column name="SUMMARY" label="SUMMARY">Threshold triggered -- Node_Down: emsda12-x11 - SNMP is not available BY ZZZZZ</column> <column name="FIRSTOCCURRENCE" label="FIRSTOCCURRENCE">05/16/2020 18:18:32</column> <column name="LASTOCCURRENCE" label="LASTOCCURRENCE">05/18/2020 18:18:32</column> <column name="ORIGINALSEVERITY" label="ORIGINALSEVERITY">2</column> <column name="SERVERNAME" label="SERVERNAME">odpemsda12x11</column> <column name="SERVERSERIAL" label="SERVERSERIAL">12345678</column> <column name="ACSCUSTOMER" label="ACSCUSTOMER">XYZ</column> <column name="ACSSMAKETICKET" label="ACSSMAKETICKET">NULL</column> </row> <metadata> <queryExecuted>select IDENTIFIER, NODE, NODEALIAS, AGENT, ALERTGROUP, ALERTKEY, SUMMARY, FIRSTOCCURRENCE, LASTOCCURRENCE, ORIGINALSEVERITY, SERVERNAME, SERVERSERIAL, ACSCUSTOMER, ACSSMAKETICKET from REPORTER_ALERT_TSO where NODE = 'odpemsda12x11'</queryExecuted> <execution-milliseconds>11</execution-milliseconds> <responseRowCount>1</responseRowCount> <responseColumnCount>14</responseColumnCount> <status>success</status> </metadata> </sqlAdapterResponse>] 

      22 May 2020 06:31:24,328 [Current Time=Fri May 22 06:31:24 GMT+12:00 2020] [Process Name=:SNOW_Testing:Select] [Root Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590085883703] [Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590085883703/:SNOW_Testing:Create Incident:start:call-process[1]] [Parent Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590085883703] [ProcessTermination=The process terminated in the completed state. The process started at 22 May 2020 06:31:23,765, terminated at 22 May 2020 06:31:24,328, and the execution took 563 milliseconds.] 22 May 2020 06:31:24,328 [Current Time=Fri May 22 06:31:24 GMT+12:00 2020] [Process Name=:SNOW_Testing:Create Incident] [Root Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590085883703] [Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590085883703] [Error=An error occurred that triggered compensation:] [TEXT= Summary: An internal error occurred which prevented successful execution completion. ] 22 May 2020 06:31:24,328 [Current Time=Fri May 22 06:31:24 GMT+12:00 2020] [Process Name=:SNOW_Testing:Create Incident] [Root Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590085883703] [Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590085883703] [StackTrace= Stack Trace: procdef:SNOW_Testing:Create Incident:start:assign[1] ] 22 May 2020 06:31:24,328 [Current Time=Fri May 22 06:31:24 GMT+12:00 2020] [Process Name=:SNOW_Testing:Create Incident] [Root Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590085883703] [Job Id=a36f2491d4052c84:-7612cbfc:1723775eada:-80001-1590085883703] [ProcessTermination=The process terminated in the compensated state. The process started at 22 May 2020 06:31:23,734, terminated at 22 May 2020 06:31:24,328, and the execution took 594 milliseconds.]