get-discovery operation
The get-discovery
operation retrieves all the available discoveries. You can filter the result by specifying a filter criterion.
The following table describes the <items>
XML and request elements for the get-discovery
operation:
Adapter request elements for the get-discovery operation
Element |
Definition |
Required |
---|---|---|
|
Specifies the operation name: |
Yes |
|
Specifies the parent element for the command elements |
Yes |
|
Specifies the duration after which the operation times out |
No |
|
Specifies the parent element for the command parameters |
Yes |
|
Specifies the parent element that contains the search criterion |
No |
|
Specifies the parent element for a single search criterion |
Conditional; required if the |
|
Specifies the name of the discovery entity property used in the search
|
Conditional; required if the |
|
Specifies the value of the property specified in the Note When specifying values like true, false, and enabled, enclose them in single quotation marks so that they are treated as strings and not as Boolean entities. |
Conditional; required if the |
|
Specifies the operation that is performed by using the values specified in the
|
Conditional; required if the |
Note
The Name
attribute of the Microsoft System Center Operations Manager 2007 application is mapped to the DisplayName
attribute of discovery entity in the Microsoft System Center Operations Manager 2007 API.
The following figure illustrates a sample adapter request for the get-discovery
operation:
Sample adapter request for the get-discovery operation
<scom-request>
<operation-name>get-discovery</operation-name>
<command-request>
<timeout-secs>120</timeout-secs>
<command-parameters>
<filters>
<filter>
<discovery-prop-key>Enabled</discovery-prop-key>
<discovery-prop-val>'true'</discovery-prop-val>
<operand>equals</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-discovery operation
<scom-response>
<metadata>
<status>success</status>
<count>1</count>
</metadata>
<commands-output>
<command-output>
<metadata>
<command>./Microsoft.EnterpriseManagement.OperationsManager.ClientShell.
Startup.ps1;get-discovery | where-object {$_.Enabled -eq 'true'}</command>
<execution-milliseconds>13468</execution-milliseconds>
<exit-code>0</exit-code>
<status>success</status>
<count>90</count>
</metadata>
<output>
<item>
<ManagementGroup>M1</ManagementGroup>
<ManagementGroupId>ae1fcf8a-8088-31d8-93ec-90fe77a32d44</ManagementGroupId>
<HasNonCategoryOverride>False</HasNonCategoryOverride>
<Enabled>true</Enabled>
<Target>ManagementPackElementUniqueIdentifier=ea99500d-8d52-fc52-b5a5-
10dcd1e9d2bd</Target>
<ConfirmDelivery>True</ConfirmDelivery>
<Remotable>True</Remotable>
<Priority>Normal</Priority>
<Category>Discovery</Category>
<DataSource>DS</DataSource>
<DiscoveryClassCollection>{ManagementPackElementUniqueIdentifier=7337a
aee-2045-5d32-0aa8-fb6e9c58078f}</DiscoveryClassCollection>
<DiscoveryRelationshipCollection>{}</DiscoveryRelationshipCollection>
<XmlTag>Discovery</XmlTag>
<Name>Microsoft.SystemCenter.ACS.Collector.Discovery</Name>
<Id>5b73d0a7-9eb3-d08f-901e-03e95e1850b4</Id>
<DisplayName>Microsoft Audit Collection Services Collector Discovery
Rule</DisplayName>
<Description>This rule discovers the Microsoft Audit Collection Service
Collector service</Description>
<LanguageCode>ENU</LanguageCode>
<Comment />
<Status>Unchanged</Status>
<LastModified>1/8/2009 10:12:53 AM</LastModified>
<TimeAdded>1/8/2009 10:12:54 AM</TimeAdded>
</item>
...
</output>
</command-output>
</commands-output>
</scom-response>
Comments
Log in or register to comment.