get-agentpendingaction operation

The get-agentpendingaction operation retrieves the actions which are pending with agents. You can filter the result by specifying a filter criterion.

The following table describes the <items> XML and request elements for the get-agentpendingaction operation:

Adapter request elements for the get-agentpendingaction operation

Element

Definition

Required

<operation-name>

Specifies the operation name: get-agentpendingaction

Yes

<command-request>

Specifies the parent element for the command elements

Yes

<timeout-secs>

Specifies the duration after which the operation times out

Default value: 60 seconds

No

<command-parameters>

Specifies the parent element for the command parameters

Yes

<filters>

Specifies the parent element that contains the search criterion

No

<filter>

Specifies the parent element for a single search criterion

You can specify more than one filter criterion by using multiple <filter> elements.

Conditional; required if the <filters> element is specified

<agent-pending-action-key>

Specifies the key that is used to locate an agent

Valid values:

  • AgentName
  • ManagementServerName
  • AgentPendingActionType
  • ManagementGroup
  • ManagementGroupId

Conditional; required if the <filters> element is specified

<agent-pending-action-val>

Specifies the value of the key specified in the <agent-pending-action-key> element

Conditional; required if the <filters> element is specified

<operand>

Specifies the operation that is performed by using the values specified in the <agent-pending-action-key> and <agent-pending-action-val> elements

Valid values:

  • equals
  • not equals
  • matches

Conditional; required if the <filters> element is specified

The following figure illustrates a sample adapter request for the get-agentpendingaction operation: 

Sample adapter request for the get-agentpendingaction operation

<scom-request>
  <operation-name>get-agentpendingaction</operation-name>
  <command-request>
    <timeout-secs>120</timeout-secs>
    <command-parameters>
      <filters>
        <filter>
          <agent-pending-action-key>AgentName</agent-pending-action-key>
          <agent-pending-action-val>abc.neuron.com</agent-pending-action-val>
          <operand>matches</operand>
        </filter>
      </filters>
    </command-parameters>
  </command-request>
</scom-request>



The following figure illustrates the adapter response for the sample request: 

Sample adapter response for the get-agentpendingaction operation

<scom-response>
  <metadata>
    <status>success</status>
    <count>1</count>
  </metadata>
  <commands-output>
    <command-output>
      <metadata>
        <command>./Microsoft.EnterpriseManagement.OperationsManager.ClientShell.
        Startup.ps1;get-agentpendingaction | where-object {$_.AgentName -match
         'abc.neuron.com'}</command>
        <execution-milliseconds>3390</execution-milliseconds>
        <exit-code>0</exit-code>
        <status>success</status>
        <count>1</count>
      </metadata>
      <output>
        <item>
          <AgentName>abc.neuron.com</AgentName>
          <ManagementServerName>win2stdvm.neuron.com</ManagementServerName>
          <AgentPendingActionType>PushInstallFailed</AgentPendingActionType>
          <LastModified>1/27/2009 6:41:11 AM</LastModified>
          <ManagementGroup>M1</ManagementGroup>
          <ManagementGroupId>ae1fcf8a-8088-31d8-93ec-90fe77a32d44</ManagementGroupId>
        </item>
      </output>
    </command-output>
  </commands-output>
</scom-response>
Was this page helpful? Yes No Submitting... Thank you

Comments