开发者

Retrieve Datasource Statistics on JBoss

How would i programm开发者_运维百科atically retrieve usage statistics for datasources deployed on JBoss? Its possible with GlassFish, however lost on how to do the same for JBoss.


You can use JavaMelody to have statistics on sql or http requests, jdbc connections and more.


You can do that via JMX.

For a start, go to http://localhost:8080/jmx-console and search for the JNDI name of the data source. This will show ~ 3 mbeans per datasource from where you can then get the statistics.

Of course you can get at the data programmatically - just follow the AMX example in your glassfish link on how to talk to the MBeanServer - of course you need to change the ObjectNames and Attribut names to reflect the JBoss ones.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜