Reading the datasource's statistics

In this recipe, you will learn how to enable the statistics of the datasource to check whether we are getting the most out of it, or if we need to tune something with the datasource, or at worst, scale with the database.

Getting ready

To get an idea of what is going on with our datasource, let's generate some traffic towards the database. In this case, we will use the application named datasource-traffic-generator. To obtain the artifact to deploy, please refer to the Software prerequisites recipe in Chapter 1, Welcome to WildFly!. Furthermore, in the source code of the application, you can find an Apache JMeter (also JMeter) project, available at the following path: datasource-traffic-generator/src/main/resources/HTTP ...

Get WildFly Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.