jmx4perl/config/wildfly.cfg
2017-10-31 14:38:28 +01:00

135 lines
4.5 KiB
INI

# Wildfly (JBoss AS 8) specific checks
# ========================================================
include "common.cfg"
# Wildfly use Undertow instead of Tomcat as its servlet container,
# webapp specific metrics changed completely.
# Requests per minute for a servlet within a deployed war
# $0: Web-Module name (i.e. the WAR file name)
# $1: Servlet name
# $2: Critical (optional)
# $3: Warning (optional)
# $4: Descriptive name (optional)
<Check wildfly_war_servlet_requests>
MBean = jboss.as.expr:subsystem=undertow,deployment=$0,servlet=$1,*
Use = count_per_minute("requests")
Attribute = requestCount
Name = ${4:request}
Critical = ${2:6000}
Warning = ${3:5000}
</Check>
# Average request processing time for a servlet within a deployed war
# $0: Web-Module name (i.e. the WAR file name)
# $1: Servlet name
# $2: Critical (optional)
# $3: Warning (optional)
# $4: Descriptive name (optional)
<Check wildfly_war_servlet_request_time>
Value = jboss.as.expr:subsystem=undertow,deployment=$0,servlet=$1,*/totalRequestTime
Base = jboss.as.expr:subsystem=undertow,deployment=$0,servlet=$1,*/requestCount
Delta
Label = $0 : $1 : %2.2f ms average request time
Name = ${4:$0-$1-request-time}
Critical = ${2:6000}
Warning = ${3:5000}
</Check>
# Requests per minute for a servlet, deployed as part of an ear
# $0: EAR Module (name of the EAR file)
# $1: Web-Module name (i.e. the WAR file name within the EAR)
# $2: Servlet name
# $3: Critical (optional)
# $4: Warning (optional)
# $5: Descriptive name (optional)
<Check wildfly_ear_servlet_requests>
MBean = jboss.as.expr:subsystem=undertow,deployment=$0,subdeployment=$1,servlet=$2,*
Use = count_per_minute("requests")
Attribute = requestCount
Name = ${5:request}
Critical = ${3:6000}
Warning = ${2:5000}
</Check>
# Average request processing time, deployed as part of an ear
# $0: EAR Module name (i.e. the EAR file name)
# $1: Web-Module name (i.e. the WAR file name)
# $2: Servlet name
# $3: Critical (optional)
# $4: Warning (optional)
<Check wildfly_ear_servlet_request_time>
Value = jboss.as.expr:subsystem=undertow,deployment=$0,subdeployment=$1,servlet=$2,*/totalRequestTime
Base = jboss.as.expr:subsystem=undertow,deployment=$0,subdeployment=$1,servlet=$2,*/requestCount
Delta
Label = $0 : $1 : $2 : %2.2f ms average request time
Name = $0-$1-$2-request
Critical = ${3:6000}
Warning = ${4:5000}
</Check>
# Check whether the webapplications deployment is in status OK
# $0: Web-Module name (i.e. the WAR file name)
# $1: Name (optional)
<Check wildfly_deployment_status>
Value = jboss.as.expr:deployment=$0/status
String = 1
Critical = !OK
Label = $0 status
Name = ${1:status}
</Check>
# Check whether a webapplication is enabled
# $0: Web-Module name (i.e. the WAR file name)
# $1: Name (optional)
<Check wildfly_deployment_enabled>
Value = jboss.as.expr:deployment=$0/enabled
String = 1
Critical = !true
Label = $0 enabled
Name = ${1:enabled}
</Check>
# Check number of active session for a webapp, deployed as a war
# $0: Web-Module name (i.e. the WAR file name)
# $1: Critical (optional) (absolute number of active sessions allowed)
# $2: Warning (optional) (absolute number of active sessions allowed)
# $3: Descriptive name (optional)
<Check wildfly_war_webapp_active_sessions>
Value = jboss.as.expr:subsystem=undertow,deployment=$0/activeSessions
Label = %v active sessions
Name = ${3:active sessions}
Critical = ${1:1000}
Warning = ${2:800}
</Check>
# Check number of active session for a webapp, deployed as part of an ear
# $0: EAR Module (name of the EAR file)
# $1: Web-Module name (i.e. the WAR file name within the ear)
# $2: Critical (optional) (absolute number of active sessions allowed)
# $3: Warning (optional) (absolute number of active sessions allowed)
# $4: Descriptive name (optional)
<Check wildfly_ear_webapp_active_sessions>
Value = jboss.as.expr:subsystem=undertow,deployment=$0,subdeployment=$1/activeSessions
Label = %v active sessions
Name = ${4:active sessions}
Critical = ${2:1000}
Warning = ${3:800}
</Check>
# Check for available database connections
# $0: Name of datasource (e.g. "ExampleDS")
# $1: Critical value (optional, default: 1)
# $2: Warning value (optional, default: 5)
# $3: Name (optional)
<Check wildfly_datasource_connections>
Value = jboss.as.expr:data-source=${0},statistics=pool,subsystem=datasources/AvailableCount
Name = ${3:dbpool_available}
Label = %.2v DB connections available
Critical = ${1:1:}
Warning = ${2:5:}
</Check>