-->
edocs Home > Oracle WebLogic Server Documentation > Administration Console Online Help > Use the Query LanguageUse the Query Language to Create a Watch Expression
A watch rule expression may include the following:
- Variable names. This differs based on the type of rule expression. (See the tables below.)
- Specified threshold values: String, Integer, Long, Double, Boolean constant
- Operators: <, >, <=, >=, =, !=, AND, OR, NOT, MATCHES, LIKE
You can create watches based on log events, on harvested attributes, and on attributes of records from instrumentation events (triggered by diagnostic monitors). The variables you use to create the expression are different, depending on the type of watch. The variables available for each of these type explained below, in the following tables.
A log event rule expression refers to attributes of a log message from the server log. The following table shows the variable names for those attributes:
Variable Descriptioin Data Type Id ID of the log message (usually starts with "BEA="). String MachineName Name of of machine that generated the log message. String ServerName Name of of server that generated the log message. String ThreadName Name of of thread that generated the log message. String UserId ID of the user that generated the log message. String TransactionId JTA transaction ID of thread that generated the log message. String Severity I18N severity text of log message. These values are OFF, EMERGENCY, ALERT, CRITICAL, NOTICE, ERROR, WARNING, INFO, DEBUG, and TRACE. String Subsystem Name of of subsystem emitting the log message. String Timestamp Timestamp when the log message was created. Long LogMessage Message content of the log message. String Throwable Exception associated with this log event. This is created by calling the toString method of the exception.
String An example log event rule expression is:
(Severity = 'Warning') AND (Id = 'BEA-320012')
An instrumentation event data rule expression refers to attributes of a data record from the instrumentation event. The following table shows the variable names for those attributes:
Variable Descriptioin Data Type Timestamp Timestamp when the instrumentation event was created. Long ContextId Diagnostic context ID of instrumentation event. String TransactionId JTA transaction ID of thread that created the instrumentation event. String UserId ID of the user that created the instrumentation event. String ActionType Type of instrumentation action. String DomainName Name of of domain. String ServerName Name of of server that created the instrumentation event. String ScopeName Name of of instrumentation scope. String MonitorType Type of monitor. String SourceFile Source file name. String LineNumber Line number in source file. Integer ClassName Class name of joinpoint. String MethodName Method name of joinpoint. String MethodDescriptor Method arguments of joinpoint. String ReturnValue Return value of joinpoint. String Payload Payload of instrumentation event. String An example instrumentation event data rule expression is:
(ActionType = 'ThreadDumpAction')A harvesterrule expression refers to attributes thata are being harvested. The expression must include an ObjectName or ObjectName pattern. For more information, see "Configuring the Types of Data to Harvest".
The following example shows an expression that includes the complete MBean ObjectName.
${mydomain:Name=HarvesterRuntime,Location=myserver,Type=HarvesterRuntime,ServerRuntime=myserver,Attribute=TotalSamplingCycles} > 10} } (document.images){ dcs_imgarray[dcs_ptr] = new Image; dcs_imgarray[dcs_ptr].src = dcs_src; WT[myMeta.name.substring(3)]=myMeta.content; } if DCSext[myMeta.name.substring(7)]=myMeta.content; } } } } for (N in DCS){P+=A( N, DCS[N]);} for (N in WT){P+=A( "WT."+N, WT[N]);} for (N in DCSext){P+=A( N, DCSext[N]);} //} aCrumb=aCookie[i].split("="); if (crumb==aCrumb[0]){ return aCrumb[1]; } } return null; } i=0;i