Web Sites Service Instance Discovery.

Microsoft.WebSites.Service.Discovery (Discovery)

Registry Discovery to discover Web Sites Service Instance class.

Knowledge Base article:

Summary

Registry Discovery to discover Web Sites Service class.

Element properties:

TargetMicrosoft.WebSites.RoleInstance
EnabledTrue
Frequency14400
RemotableFalse

Object Discovery Details:

Discovered Classes and their attribuets:

Member Modules:

ID Module Type TypeId RunAs 
DS DataSource Microsoft.Windows.FilteredRegistryDiscoveryProvider Default

Source Code:

<Discovery ID="Microsoft.WebSites.Service.Discovery" Target="Microsoft.WebSites.RoleInstance" Enabled="true" ConfirmDelivery="false" Remotable="true" Priority="Normal">
<Category>Discovery</Category>
<DiscoveryTypes>
<DiscoveryClass TypeID="Microsoft.WebSites.Service">
<Property TypeID="Microsoft.WebSites.Service" PropertyID="Name"/>
<Property TypeID="System!System.Entity" PropertyID="DisplayName"/>
</DiscoveryClass>
</DiscoveryTypes>
<DataSource ID="DS" TypeID="Windows!Microsoft.Windows.FilteredRegistryDiscoveryProvider">
<ComputerName>$Target/Property[Type="Microsoft.WebSites.RoleInstance"]/Name$</ComputerName>
<RegistryAttributeDefinitions>
<RegistryAttributeDefinition>
<AttributeName>IsWebSitesRole</AttributeName>
<Path>SOFTWARE\Microsoft\IIS Extensions\Web Hosting Framework</Path>
<!--
PathType
0 Key. Path is full path to the key.
1 Value of specified registry key. Path includes name of the value.
2 Default value of specified registry key. Path is full path to the key.
-->
<PathType>0</PathType>
<!--
AttributeType
0 Boolean: used when checking existence of the key or value.
1 String: converting result value to string if possible.
2 Integer: converting result value to number if possible.
3 Float: converting result value to float.
-->
<AttributeType>0</AttributeType>
</RegistryAttributeDefinition>
<RegistryAttributeDefinition>
<AttributeName>StampName</AttributeName>
<Path>SOFTWARE\Microsoft\IIS Extensions\Web Hosting Framework\StampName</Path>
<PathType>1</PathType>
<AttributeType>1</AttributeType>
</RegistryAttributeDefinition>
</RegistryAttributeDefinitions>
<!-- 14400s: 4 hrs -->
<Frequency>14400</Frequency>
<ClassId>$MPElement[Name="Microsoft.WebSites.Service"]$</ClassId>
<InstanceSettings>
<Settings>
<Setting>
<Name>$MPElement[Name="Microsoft.WebSites.Service"]/Name$</Name>
<Value>$Data/Values/StampName$</Value>
</Setting>
<Setting>
<Name>$MPElement[Name="System!System.Entity"]/DisplayName$</Name>
<Value>Web Sites Service ($Data/Values/StampName$)</Value>
</Setting>
</Settings>
</InstanceSettings>
<Expression>
<SimpleExpression>
<ValueExpression>
<XPathQuery Type="String">Values/IsWebSitesRole</XPathQuery>
</ValueExpression>
<Operator>Equal</Operator>
<ValueExpression>
<Value Type="String">true</Value>
</ValueExpression>
</SimpleExpression>
</Expression>
</DataSource>
</Discovery>