7 Replies Latest reply on Sep 4, 2015 6:59 PM by laurensto

    JBoss EAP 6.3.0 does not show Data Source Metrics

    jorsol

      In JBoss EAP 6.3.0 in the web console under Runtime - Datasources, it's not showing the data source Pool Usage and Prepared Statement Cache metrics...


      in the log file either:

      16:00:12,250 DEBUG [org.jboss.jca.core.connectionmanager.pool.strategy.OnePool] (ajp-/0.0.0.0:8109-4) SQLServer-Pool: getConnection(null, WrappedConnectionRequestInfo@69a83509[userName=dbuser]) [0/100]

      16:00:12,255 DEBUG [org.jboss.jca.core.connectionmanager.pool.strategy.OnePool] (ajp-/0.0.0.0:8109-4) SQLServer-Pool: returnConnection(4018fb68, false) [0/100]

        • 1. Re: JBoss EAP 6.3.1 does not show Data Source Metrics
          ctomc

          EAP 6.3.1? there is no such release at this time.

          • 2. Re: JBoss EAP 6.3.0 does not show Data Source Metrics
            jorsol

            You are right Tomaz, It's a typo, I corrected it...

             

            In EAP 6.3.0 the web console don't show the metrics.

            • 3. Re: JBoss EAP 6.3.0 does not show Data Source Metrics
              chriscab916

              Any solution to this?  I would also like to know how to enable the datasource metrics.

               

              In the cli, i ran the following (running in domain mode):

              /host=hostname/server=servername/subsystem=datasources/data-source=datasourcename/statistics=pool :read-resource(recursive=true, include-runtime=true)

               

              but got all 0s in the result:

              {

                  "outcome" => "success",

                  "result" => {

                      "ActiveCount" => "0",

                      "AvailableCount" => "0",

                      "AverageBlockingTime" => "0",

                      "AverageCreationTime" => "0",

                      "CreatedCount" => "0",

                      "DestroyedCount" => "0",

                      "InUseCount" => "0",

                      "MaxCreationTime" => "0",

                      "MaxUsedCount" => "0",

                      "MaxWaitCount" => "0",

                      "MaxWaitTime" => "0",

                      "TimedOut" => "0",

                      "TotalBlockingTime" => "0",

                      "TotalCreationTime" => "0",

                      "statistics-enabled" => false

                  }

              }

              • 4. Re: JBoss EAP 6.3.0 does not show Data Source Metrics
                jdoyle

                Try flipping the "statistics-enabled" property to true.

                • 5. Re: JBoss EAP 6.3.0 does not show Data Source Metrics
                  ctomc

                  do something along the lines of

                   

                  /host=hostname/server=servername/subsystem=datasources:write-attribute(name="statistics-enabled", value=true)

                  • 6. Re: JBoss EAP 6.3.0 does not show Data Source Metrics
                    chriscab

                    I forgot to say thanks back then, so thanks all!

                     

                    Anyone know if there's a way to permanently enable these datasource statistics?  There's no instance of a "statistics-enabled" attribute in any of the config files in the domain/configuration folder, so does that mean the attribute is only available during runtime?  The statistics are disabled whenever the server is restarted.

                    • 7. Re: JBoss EAP 6.3.0 does not show Data Source Metrics
                      laurensto

                      You can try adding by the attribute statistics-enabled="true" to your datasource definition in e.g. standalone.xml.

                       

                      <datasource jndi-name="java:jboss/datasources/ExampleDS" pool-name="ExampleDS" enabled="true" use-java-context="true" statistics-enabled="true">

                       

                      The statistics are then enabled whenever the server is restarted.