zoukankan      html  css  js  c++  java
  • JDBC监控工具p6spy

    p6spy: 

    http://www.p6spy.com/ 

    An open source Java tool that intercepts and logs all database statements that use JDBC

    JDBC SQL Profiler: 

    http://sourceforge.net/projects/sqlprofiler/

    Have you ever wondered which database indexes you should create for your JDBC-based application ? This Swing-based SQL profiler tries to offer a tool to monitor which tables and columns are accessed the most in SQL queries to recommend index creation.

    IronTrack SQL: 

    http://www.irongrid.com/ironeyesql 

    IronTrack SQL increases the visibility of performance problems from build to build through time-based views of JDBC performance metrics. IronTrack SQL easily enables Java performance tuning by displaying database usage over time, Overlaying and comparing performance datasets, and embedding performance testing with no source code changes. 

    参考:

    http://netfork.javaeye.com/blog/286789

    http://www.ibm.com/developerworks/cn/java/j-lo-p6spy/index.html

    基本使用步骤: 

    1、把 P6Spy 的 jar 包 p6spy.jar 放到 CLASSPATH 中,如果是 Web 应用程序则放在 YourWebApp/WEB-INF/lib/ 目录下; 

    2、把 spy.properties 放到 CLASSPATH 目录下,如果是 Web 应用程序放在 YourWebApp/WEB-INF/classess/ 目录下,注意不是 lib/ 目录 

    3、修改你应用系统中的数据库驱动名称为 P6Spy 的驱动程序名称 com.p6spy.engine.spy.P6SpyDriver 其它的全部使用默认值,暂时先都不用修改; 

    4、打开配置文件 spy.properties 文件,找到 realdriver,把它的值改为你的应用系统的真正的数据库驱动名称; 

    5、运行你的应用程序或 Web 应用程序,可以在tomcat的bin目录下的spy.log 里看到 P6Spy 监测到的 SQL 详细的执行与操作的记录信息了,包含有完整的 SQL 执行参数。 

    ----------- 软件性能测试工作室:提供性能测试咨询、培训和项目指导 (QQ: 2225045276 E-Mail: Testing_is_believing@126.com)
  • 相关阅读:
    有点忙啊
    什么是协程
    HDU 1110 Equipment Box (判断一个大矩形里面能不能放小矩形)
    HDU 1155 Bungee Jumping(物理题,动能公式,弹性势能公式,重力势能公式)
    HDU 1210 Eddy's 洗牌问题(找规律,数学)
    HDU1214 圆桌会议(找规律,数学)
    HDU1215 七夕节(模拟 数学)
    HDU 1216 Assistance Required(暴力打表)
    HDU 1220 Cube(数学,找规律)
    HDU 1221 Rectangle and Circle(判断圆和矩形是不是相交)
  • 原文地址:https://www.cnblogs.com/preftest/p/2172356.html
Copyright © 2011-2022 走看看