Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Universal Monitor Task: XML and JSON Examples

The retainSysIds and version properties are specified as attributes in XML.

The exportReleaseLevel and /wiki/spaces/UC71x/pages/5179227 exportTable properties are specified as attributes in XML.

...

Examples

XML

JSON

Example for Task


title
Expand


Code Block
language
XML
text
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<taskUniversalMonitor exportReleaseLevel="7.
2
5.0.0" exportTable="ops_task_universal_monitor" retainSysIds="true" version="
1
4">
    <variables/>
   
<actions
 <notes/>
    <eventBusinessServiceCriteria>Member of 
<variables />
Specific Business Services or Unassigned</eventBusinessServiceCriteria>
    <eventBusinessServices>
       
<notes
 <businessService>X</
>
businessService>
       
<virtualResources
 <businessService>Y</
>
businessService>
       
<exclusiveTasks
 <businessService>Z</
>
businessService>
    <
avgRunTime>3<
/
avgRunTime>
eventBusinessServices>
    <cpDuration 
<avgRunTimeDisplay>3 Seconds<
/
avgRunTimeDisplay
>
    <cpDurationUnit>Minutes</cpDurationUnit>
   
<cpDuration
 <customField1/>
    <customField2/>
  
<cpDurationUnit>Minutes</cpDurationUnit>
  <efDayConstraint>None</efDayConstraint>
    <efDuration>00:00:00:00</efDuration>
   
<credentials
 <efEnabled>false</
>
efEnabled>
    <efNthAmount>5</efNthAmount>
   
<credentialsVar
 <efOffsetDuration />
    <efOffsetDurationUnit>Minutes</efOffsetDurationUnit>
   
<customField1 label="Domain">web.com</customField1>
 <efOffsetPercentage>0</efOffsetPercentage>
    
<customField2 />
<efOffsetType>Percentage</efOffsetType>
    
<efTime>00:00</efTime>
 
<efDayConstraint>Nth</efDayConstraint>
   <efType>Time</efType>
    
<efDuration>00:00:00:00</efDuration>
<enforceVariables>false</enforceVariables>
    <eventTemplate label="UAC - 
<efEnabled>false</efEnabled>
Agent Changed">uac_agent_changed</eventTemplate>
    <eventType>Global</eventType>
  
<efNthAmount>10</efNthAmount>
 
  
 
 
<exclusiveWithSelf>false</exclusiveWithSelf>
  
 
 
<efOffsetDuration
 <executionRestriction>None</
>
       <efOffsetDurationUnit>Minutes</efOffsetDurationUnit>
       <efOffsetPercentage>0</efOffsetPercentage>
       <efOffsetType>Percentage</efOffsetType>
       <efTime>00:00</efTime>
executionRestriction>
    <expirationAction>Failed</expirationAction>
    <filter>
   
<efType>Time</efType>
     <logicalOperator>And</logicalOperator>
 
<eventTemplate
 
/>
  </filter>
    
<eventType>Local/<eventType>
<firstRun></firstRun>
    <holdResources>false</holdResources>
  
<executionRestriction>Run</executionRestriction>
  <lastRun></lastRun>
    
<expirationAction>Finished</expirationAction>
<lfDayConstraint>None</lfDayConstraint>
    <lfDuration>00:00:00:00</lfDuration>
 
<filter>
   <lfEnabled>false</lfEnabled>
    <lfNthAmount>5</lfNthAmount>
  
<criterion>
  <lfOffsetDuration />
    <lfOffsetDurationUnit>Minutes</lfOffsetDurationUnit>
    
<name>tfield</name>
<lfOffsetPercentage>0</lfOffsetPercentage>
    <lfOffsetType>Percentage</lfOffsetType>
    <lfTime>00:00</lfTime>
    
<operator>NOT_EQUALS</operator>
<lfType>Time</lfType>
    <lockVariables>false</lockVariables>
    <logLevel>Inherited</logLevel>
    
<value>Test<
<lsDayConstraint>None</
value>
lsDayConstraint>
    <lsDuration>00:00:00:00</lsDuration>
    
<
<lsEnabled>false</
criterion>
lsEnabled>
    <lsNthAmount>5</lsNthAmount>
    
<logicalOperator>And</logicalOperator>
<lsTime>00:00</lsTime>
    <lsType>Time</lsType>
 
</filter>
   <name>UM</name>
    <actions/>
  
<firstRun>2021-03-15
 
13:59:37 -0400</firstRun
 <opswiseGroups/>
    <relativeTimeFrom>00:00</relativeTimeFrom>
  
<holdResources>false</holdResources>
  <relativeTimeTo />
    <resPriority>10</resPriority>
   
<lastRun>2021-03-16 17:12:42 -0400</lastRun>
 <resolveNameImmediately>false</resolveNameImmediately>
    <restrictionPeriod>None</restrictionPeriod>
    
<restrictionPeriodAfterDate 
<lfDayConstraint>Nth<
/
lfDayConstraint
>
    
<lfDuration>00:00:00:00</lfDuration
<restrictionPeriodAfterTime />
    <restrictionPeriodBeforeDate 
<lfEnabled>false<
/
lfEnabled
>
    
<restrictionPeriodBeforeTime 
<lfNthAmount>1<
/
lfNthAmount
>
  
 
 
 
 
 
<lfOffsetDuration
 <restrictionPeriodDateList/>

      

<lfOffsetDurationUnit>MInutes</lfOffsetDurationUnit>
   
 
  
 
<lfOffsetPercentage>0</lfOffsetPercentage>
   
 
  
 
<lfOffsetType>Percentage</lfOffsetType>
       <lfTime>00:00</lfTime>
<runCount>0</runCount>
    <runTime>0</runTime>
    
<lfType>Time</lfType>
<simulation>false</simulation>
    <startHeld>false</startHeld>
    
<lsDayConstraint>Nth<
<startHeldReason /
lsDayConstraint
>
    <summary />
 
<lsDuration>00:00:00:00</lsDuration>
   <sysId>36d6cd11669751098963c8f3eb2250ef</sysId>
    
<lsEnabled>false<
<exclusiveTasks/
lsEnabled
>
    <virtualResources/>
  
<lsNthAmount>7</lsNthAmount>
  <taskUniversal />
    
<lsTime>00:00<
<taskUniversalVariables/
lsTime
>
    
<template 
<lsType>Time<
/
lsType
>


    <templateEventTemplate />
<name>uc
    <timeScope>-- 
Test
None 
Email</name>
--</timeScope>
    <timeZonePref>-- System Default --<
opswiseGroups
/
>
timeZonePref>

    <twDelayAmount 
<relativeTimeFrom>00:00<
/
relativeTimeFrom
>


    <twDelayDuration>00:00:00:00</twDelayDuration>
 
<relativeTimeTo
 
/>
  <twDelayType>None</twDelayType>
    <twWaitAmount 
<resolveNameImmediately>false<
/
resolveNameImmediately
>
    
<twWaitDayConstraint>None</twWaitDayConstraint>
 
<resPriority>10</resPriority>
   <twWaitDuration>00:00:00:00</twWaitDuration>
    
<restrictionPeriod>Span</restrictionPeriod>
<twWaitTime>00:00</twWaitTime>
    
<restrictionPeriodAfterDate>2017-11-10</restrictionPeriodAfterDate>
<twWaitType>None</twWaitType>
    <twWorkflowOnly>-- System Default --<
restrictionPeriodAfterTime>10:30</restrictionPeriodAfterTime>
/twWorkflowOnly>
    <userEstimatedDuration />
<restrictionPeriodBeforeDate>2017-11-20</restrictionPeriodBeforeDate> <restrictionPeriodBeforeTime>15:00</restrictionPeriodBeforeTime> <restrictionPeriodDateList />
<runCount>32</runCount>
<runTime>108</runTime> <startHeld>false</startHeld> <startHeldReason /> <summary>Test Email</summary> <sysId>fb59a227517a421a92c15ff5aefe3b66</sysId>
<taskUniversal>Sample1</taskUniversal>
<taskUniversalVariables>
<variable>
<name>v_enabled</name>
<value>${var}</value>
<resolution>Enabled</resolution>
</variable>
<variable>
<name>v_disabled</name>
<value>${var}</value>
<resolution>Disabled</resolution>
</variable>
</taskUniversalVariables>
<template>Test Template</template>
<templateEventTemplate label="Test Event B">test_event_b</templateEventTemplate>
<timeScope>-- None --</timeScope> <timeZonePref>-- System Default --</timeZonePref> <twDelayAmount /> <twDelayDuration>00:00:00:00</twDelayDuration> <twDelayType>None</twDelayType> <twWaitAmount /> <twWaitDayConstraint>NONE</twWaitDayConstraint> <twWaitDuration>00:00:00:00</twWaitDuration> <twWaitTime>00:00</twWaitTime> <twWaitType>None</twWaitType> <twWorkflowOnly>-- System Default --</twWorkflowOnly> <userEstimatedDuration /> </taskUniversalMonitor>
Expand
titleJSON
{ "type": "taskUniversalMonitor", "actions": { "abortActions": [], "emailNotifications": [], "setVariableActions": [], "snmpNotifications": [], "systemOperations": [] },
"cpDuration": null, "cpDurationUnit": "Minutes", "customField1": { "label": "Domain", "value": "http://qa-cntlr-mssql:8080/uc/" }, "customField2": { "label": null, "value": null }, "efDayConstraint": "Nth Day", "efDuration": "00:00:00:00", "efEnabled": false, "efNthAmount": 10,   "efOffsetDuration": null, 
  "efOffsetDurationUnit": "Minutes",
  "efOffsetPercentage": 0,
  "efOffsetType": "Percentage",
  "efTime": "00:00",
  "efType": "Time", "eventTemplate": null,
"eventType": "Local", "exclusiveTasks": [], "executionRestriction": "Run",
"expirationAction": "Finished",
"exportReleaseLevel": "7.2.0.0",
"exportTable": "ops_task_universal_monitor",
"filter": {
"criteria": [
{
"type": "criterion",
"name": "tfield",
"operator": "NOT_EQUALS",
"value": "Test"
</taskUniversalMonitor>





Expand


Code Block
languagetext
{
    "type": "taskUniversalMonitor",
    "actions": {
        "abortActions": [],
        "emailNotifications": [],
        "setVariableActions": [],
        "snmpNotifications": [],
        "systemOperations": []
    },
    "cpDuration": null,
    "cpDurationUnit": "Minutes",
    "customField1": {
        "label": null,
        "value": null
    },
    "customField2": {
        "label": null,
        "value": null
    },
    "efDayConstraint": "None",
    "efDuration": "00:00:00:00",
    "efEnabled": false,
    "efNthAmount": 5,
    "efOffsetDuration": null,
    "efOffsetDurationUnit": "Minutes",
    "efOffsetPercentage": 0,
    "efOffsetType": "Percentage",
    "efTime": "00:00",
    "efType": "Time",
    "enforceVariables": false,
    "eventBusinessServiceCriteria": "Member of Specific Business Services or Unassigned",
    "eventBusinessServices": [
        "X",
}
      
],
  "Y",
   
"logicalOperator":
 
"And",
  
}
  "
firstRun
Z"
: "2021-03-15 13:59:37 -0400",

    ],
    "
holdResources
eventTemplate":
false,
 {
        "
lastRun
label": "
2021-03
UAC -
16
 
17:12:42 -0400",
Agent Changed",
        "
lastRunTime
value": 
9,
"lastRunTimeDisplay": "9 Seconds"
"uac_agent_changed"
    },
    "
lfDayConstraint
eventType": "
Nth Day
Global",
    "
lfDuration
exclusiveTasks": 
"00:00:00:00"
[],
    "
lfEnabled
exclusiveWithSelf": false,
    "
lfNthAmount
executionRestriction": 
1
"None",
 
 
"lfOffsetDuration":
 
null, 
 

 
 "
lfOffsetDurationUnit
expirationAction": "
Minutes
Failed",

 

    "
lfOffsetPercentage
exportReleaseLevel": "7.5.0.0
,
 
",
    "
lfOffsetType
exportTable": "
Percentage
ops_task_universal_monitor",

 

    "
lfTime
filter": 
"00:00",
{
        "
lfType
logicalOperator": "
Time
And"
,

  
"lsDayConstraint":
 
"Nth
 
Day"
},
    "
lsDuration
firstRun": "
00:00:00:00
",
    "
lsEnabled
holdResources": false,
    "
lsNthAmount
lastRun": 
7
"",
    "
lsTime
lfDayConstraint": "
00:00
None",
    "
lsType
lfDuration": "
Time
00:00:00:00",


    "
name
lfEnabled":
"uc - Test Email",
 false,
    "
notes
lfNthAmount": 
[]
5,
    "
opswiseGroups
lfOffsetDuration": null,
  

  "
relativeTimeFrom
lfOffsetDurationUnit": "
00:00
Minutes",


    "
relativeTimeTo
lfOffsetPercentage": 
null
0,
    "
resolveNameImmediately
lfOffsetType": 
false
"Percentage",
    "
resPriority
lfTime": 
10,
"00:00",
    "
restrictionPeriod
lfType": "
Span
Time"
,
,
    "
restrictionPeriodAfterDate
lockVariables": 
"2017-11-10"
false,
    "
restrictionPeriodAfterTime
logLevel": "
10:30
Inherited",
    "
restrictionPeriodBeforeDate
lsDayConstraint": "
2017-11-20
None",
    "
restrictionPeriodBeforeTime
lsDuration": "
15
00:00:00:00",
  
"restrictionPeriodDateList":
 
[],
 "
retainSysIds
lsEnabled": 
true
false,


 
"runCount":
 
32,
  "
runTime
lsNthAmount": 
108
5,
    "
startHeld
lsTime": 
false,
"00:00",
    "
startHeldReason
lsType": 
null
"Time",
    "
summary
name": "
Test Email
UM",
    "
sysId
notes": 
"fb59a227517a421a92c15ff5aefe3b66",
[],
    "
taskUniversal
opswiseGroups": 
"Sample1",
[],
    "relativeTimeFrom"
taskUniversalVariables
: "00:00",
[
    "relativeTimeTo": null,
    
{
"resPriority": 10,
    
"resolveNameImmediately": false,
    
"
name
restrictionPeriod": "
v_enabled
None",


    
"restrictionPeriodAfterDate": null,
    
"
resolution
restrictionPeriodAfterTime": 
"Enabled"
null,


    
"restrictionPeriodBeforeDate": null,
    "
value
restrictionPeriodBeforeTime": 
"${var}"
null,
    
},
"restrictionPeriodDateList": [],
    "retainSysIds": true,
   
{
 "runCount": 0,
    "runTime": 0,
    
"
name
simulation": 
"v_disabled"
false,


    
"startHeld": false,
    "
resolution
startHeldReason": 
"Disabled"
null,


    
"summary": null,
    "
value
sysId": "
${var}"
36d6cd11669751098963c8f3eb2250ef",
    
"taskUniversal": null,
  
}
  
]
"
template
taskUniversalVariables": 
"Test Template",
"templateEventTemplate":
[],
    "
label
template": 
"Test Event B",
null,
    
"
value
templateEventTemplate":
test_event_b"
 null,
  
},
  "timeScope": "-- None --",
    "timeZonePref": "-- System Default --",
    "twDelayAmount": null,
    "twDelayDuration": "00:00:00:00",
    "twDelayType": "None",
    "twWaitAmount": null,
    "twWaitDayConstraint": "
NONE
None",
    "twWaitDuration": "00:00:00:00",
    "twWaitTime": "00:00",
    "twWaitType": "None",
    "twWorkflowOnly": "-- System Default --",
    "userEstimatedDuration": null,
    "variables": [],
    "version": 
1
4,
    "virtualResources": []
}




See Task Web Services - Task Actions for XML and JSON examples of task actions.

...