Active Version State

Microsoft.JEE.WebLogic.11gR1.Deep.Application.ActiveVersionState.AvailabilityHealth.UnitMonitor (UnitMonitor)

Monitors the active version state of the deployed applications for a WebLogic 11gR1 application server.

Knowledge Base article:

Summary

The application active version state availability health monitor tracks the active version state of the application runtime. The query for all available application runtimes is used:

Causes

A warning indicates that the monitored application is either in a PREPARED OR UNPREPARED state.

Resolutions

Applications in a warning state are not actively deployed. Use the WebLogic console to complete the deployment process for the application.

Element properties:

TargetMicrosoft.JEE.WebLogic.11gR1.Application
Parent MonitorSystem.Health.AvailabilityState
CategoryAvailabilityHealth
EnabledTrue
Alert GenerateTrue
Alert SeverityMatchMonitorHealth
Alert PriorityNormal
Alert Auto ResolveTrue
Monitor TypeMicrosoft.JEE.Deep.Application.TwoState.Query.AvailabilityHealth.MonitorType
RemotableTrue
AccessibilityPublic
Alert Message
Application is not activated
The application '{3}' is not activated. This application can be identified by the ObjectName '{2}' on the machine {1} for the application server ID '{0}'.
RunAsDefault

Source Code:

<UnitMonitor ID="Microsoft.JEE.WebLogic.11gR1.Deep.Application.ActiveVersionState.AvailabilityHealth.UnitMonitor" Accessibility="Public" Enabled="true" Target="Microsoft.JEE.WebLogic.11gR1.Application" ParentMonitorID="Health!System.Health.AvailabilityState" Remotable="true" Priority="Normal" TypeID="JEE!Microsoft.JEE.Deep.Application.TwoState.Query.AvailabilityHealth.MonitorType" ConfirmDelivery="true">
<Category>AvailabilityHealth</Category>
<AlertSettings AlertMessage="Microsoft.JEE.WebLogic.11gR1.Deep.Application.ActiveVersionState.AvailabilityHealth.UnitMonitor_AlertMessageResourceID">
<AlertOnState>Warning</AlertOnState>
<AutoResolve>true</AutoResolve>
<AlertPriority>Normal</AlertPriority>
<AlertSeverity>MatchMonitorHealth</AlertSeverity>
<AlertParameters>
<!-- The alert description should include key properties of: -->
<!-- * the application server id -->
<!-- * the application hostname -->
<!-- * the application object name-->
<!-- * the application name -->
<AlertParameter1>$Target/Host/Property[Type="JEE!Microsoft.JEE.ApplicationServer.Monitored.Instance"]/Id$</AlertParameter1>
<AlertParameter2>$Target/Host/Property[Type="JEE!Microsoft.JEE.ApplicationServer.Monitored.Instance"]/HostName$</AlertParameter2>
<AlertParameter3>$Target/Property[Type="JEE!Microsoft.JEE.Application"]/ObjectName$</AlertParameter3>
<AlertParameter4>$Target/Property[Type="JEE!Microsoft.JEE.Application"]/ApplicationName$</AlertParameter4>
</AlertParameters>
</AlertSettings>
<OperationalStates>
<OperationalState ID="Healthy" MonitorTypeStateID="Healthy" HealthState="Success"/>
<OperationalState ID="NotHealthy" MonitorTypeStateID="NotHealthy" HealthState="Warning"/>
</OperationalStates>
<Configuration>
<ComputerName>$Target/Host/Property[Type="JEE!Microsoft.JEE.ApplicationServer.Monitored.Instance"]/HostName$</ComputerName>
<Protocol>$Target/Host/Property[Type="JEE!Microsoft.JEE.ApplicationServer.Monitored.Instance"]/Protocol$</Protocol>
<Port>$Target/Host/Property[Type="JEE!Microsoft.JEE.ApplicationServer.Monitored.Instance"]/Port$</Port>
<BaseURL/>
<JMXQuery>com.bea:Type=ApplicationRuntime,*</JMXQuery>
<AdditionalArguments>&amp;MaxDepth=2</AdditionalArguments>
<RequestBody/>
<!-- This will query all of the available MBeans and -->
<!-- look for the right MBean and update the state as stated -->
<!-- in the SPEC for WebLogic: -->
<!-- * Healthy : ActiveVersionState == Active -->
<!-- * Warning : ActiveVersionState == Prepared || -->
<!-- ActiveVersionState == Unprepared -->
<HealthyExpression>
<SimpleExpression>
<ValueExpression>
<!-- The XPATH if it were applied directly against the XML in a browser should look like: -->
<!-- /MBeans/weblogic.j2ee.J2EEApplicationRuntimeMBeanImpl/Properties/ActiveVersionState[../ApplicationName = "SimpleApplication"] -->
<XPathQuery Type="String">MBeans/MBean[@Name='weblogic.j2ee.J2EEApplicationRuntimeMBeanImpl']/Properties/Property[@Name='ActiveVersionState' and ../Property[@Name='ApplicationName']="$Target/Property[Type="JEE!Microsoft.JEE.Application"]/ApplicationName$"]</XPathQuery>
</ValueExpression>
<Operator>Equal</Operator>
<ValueExpression>
<!-- 2 == Active -->
<Value Type="String">2</Value>
</ValueExpression>
</SimpleExpression>
</HealthyExpression>
<NotHealthyExpression>
<SimpleExpression>
<ValueExpression>
<!-- The XPATH if it were applied directly against the XML in a browser should look like: -->
<!-- /MBeans/weblogic.j2ee.J2EEApplicationRuntimeMBeanImpl/Properties/ActiveVersionState[../ApplicationName = "SimpleApplication"] -->
<XPathQuery Type="String">MBeans/MBean[@Name='weblogic.j2ee.J2EEApplicationRuntimeMBeanImpl']/Properties/Property[@Name='ActiveVersionState' and ../Property[@Name='ApplicationName']="$Target/Property[Type="JEE!Microsoft.JEE.Application"]/ApplicationName$"]</XPathQuery>
</ValueExpression>
<!-- Not looking for Active state, which implies that the state must either -->
<!-- be PREPARED or UNPREPARED. -->
<Operator>NotEqual</Operator>
<ValueExpression>
<!-- 2 == Active -->
<Value Type="String">2</Value>
</ValueExpression>
</SimpleExpression>
</NotHealthyExpression>
<IntervalSeconds>900</IntervalSeconds>
<TimeoutSeconds>300</TimeoutSeconds>
</Configuration>
</UnitMonitor>