Dynamic Monitoring of JDBC database access operations-p6spy and jdbcp6spy

Source: Internet
Author: User

Dynamic Monitoring of JDBC database access operations-p6spy and jdbcp6spy

P6spy is a JDBC Driver packaging tool. Through encapsulation of JDBC Driver, p6spy monitors and analyzes SQL statements for various purposes.
P6spy1.3 http://sourceforge.net/projects/p6spy/ sf.net? Source = directory

WSJdbcDataSource PoolConnectionDataSource

Ojdbc6 cannot be injected. It is confirmed that there may be version problems.

Officially confirmed that JDK 1.5 and later are not easy to use. It has been verified that it can be deployed under STS: mysql can be deployed, oracle cannot be deployed, and myeclipse can be deployed, but it cannot be deployed on WAS7, connectionPoolDataSource is not implemented at all, and there seems to be a problem in JDK 6.

Java-jar irontracksql_plus.jar can be viewed graphically. This tool can view the SQL requests sent by the application.

Module. ibeam = com. irongrid. ibeam. server. IBeamFactory

Monitorport = 2000

P6spy2 github.com https://github.com/p6spyusage

Add jar package

Direct Injection in jdbc strings

Conn = DriverManager. getConnection (

// "Jdbc: oracle: thin: @ 192.168.1.9: 1521: orcl ",

"Jdbc: p6spy: oracle: thin: @ 192.168.1.9: 1521: orcl ",

"System", "XXX ");

 

Conn = DriverManager. getConnection (

"Jdbc: p6spy: mysql: // 192.168.1.55: 3306/test ",

// "Jdbc: mysql: // 192.168.1.55: 3306/test ",

"XXX ",

"XXX ");

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.