Hibernate Statistics
Dependency :
compile ":hibernate-stats:1.1"
Summary
Description
Enables Hibernate Statistics capture and exposes an MBeanTo view the stats in a browser, browse to
http://HOST/APP_NAME/hibernateStats/Stats collection is turned off by default. To turn it on, browse to the controller provided by the plugin (http://HOST/APP_NAME/hibernateStats/) and click the link for "Turn Stats Collection On". You can also change the default by adding an entry in Config.groovy:
hibernateStats.enabled = trueThe MBean is not exposed by default - to expose the MBean, add this to your application Config.groovy:
hibernateStats.exposeMBean = trueThe plugin adds a dynamic method to your domain classes (getEntityStats) that will return the entity statistics for that particular domain class. For an example, see the HibernateStatsController entityStats actionHibernate Stats was written as an exercise for an article on how to write a Grails Plugin for the February 2009 edition of Groovy Mag (see http://www.groovymag.com/main.issues.description/id=6/).