Enabling Web/HTTP Statistic Collection: Procedure
Enabling Web/HTTP Statistic Collection: Procedure
Enabling Web/HTTP Statistic Collection: Procedure
Before the JBoss agent can gather JBoss server web metrics and other subsystem metrics,
statistics collection must be enabled for each subsystem. This procedure is for JBoss EAP version
7.x and WildFly versions 8.x, 9.x and 10.x.
Procedure
The statistics-enabled attribute of various JBoss subsystems controls statistic collection. This
setting can be viewed and updated by using the JBoss command line interface.
Note
This procedure is for JBoss EAP version 7.x and WildFly versions 8.x, 9.x and 10.x.
1. Go to the binary or bin directory under the JBoss server installation directory.
Tip
Note
If JBoss is running in Domain Mode, each command must be prefixed with the associated
profile and these commands must be run for each monitored profile. For example:
/profile=full/subsystem=ejb3:read-attribute(name=statistics-enabled)
/subsystem=ejb3:read-attribute(name=enable-statistics)
/subsystem=transactions:read-attribute(name=statistics-enabled)
/subsystem=undertow:read-attribute(name=statistics-enabled)
/subsystem=webservices:read-attribute(name=statistics-enabled)
/subsystem=datasources/data-source=Data_Source_Name:read-
attribute(name=statistics-enabled)
/subsystem=datasources/data-source=Data_Source_Name/statistics=pool:read-
attribute(name=statistics-enabled)
/subsystem=datasources/data-source=Data_Source_Name/statistics=jdbc:read-
attribute(name=statistics-enabled)
where Data_Source_Name is the name of a data source that is configured for use with JBoss.
Note
4. Run the following command to change the value of each subsystem's statistics-enabled
attribute to true:
/subsystem=ejb3:write-attribute(name=enable-statistics, value=true)
/subsystem=transactions:write-attribute(name=statistics-enabled,value=true)
/subsystem=undertow:write-attribute(name=statistics-enabled,value=true)
/subsystem=webservices:write-attribute(name=statistics-enabled,value=true)
/subsystem=datasources/data-source=Data_Source_Name:write-
attribute(name=statistics-enabled,value=true)
/subsystem=datasources/data-source=Data_Source_Name/statistics=pool:write-
attribute(name=statistics-enabled,value=true)
/subsystem=datasources/data-source=Data_Source_Name/statistics=jdbc:write-
attribute(name=statistics-enabled,value=true)
Note
Any currently running JBoss agents with transaction tracking enabled must be restarted.
Parent topic:
Configuring JBoss monitoring