Expiring Today—Celebrate National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Tracing a third party JDBCODBC application

Posted on 2007-11-27
3
Medium Priority
?
318 Views
Last Modified: 2013-12-29
I have a third party application that uses JDBC to connect to and query a database.  The performance of this application is quite poor and I would like to produce a trace of the calls that the application is making in to the JDBC driver - I have found a number of places that talk about how to enable logging of the JDBCODBC driver when you are codinging the program that is using the driver, but none on how to invoke tracing when you don't have control over the source code.    The examples I have found all involve calling java.sql.DriverManager.setLogStream(java.lang.System.out);

I have tried using P6Spy's JDBC driver, but this only logs SQLStatements executed by the application, and I would like to log all JDBC calls (the application I want to trace makes heavy use of the metadata functions within the JDBC API).

I am really hoping there's a way to invoke the trace functionality either through parameters passed in on the database connection URL or through environment variables.

Thanks for any help,
-jdc
0
Comment
Question by:clajo04
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 92

Assisted Solution

by:objects
objects earned 600 total points
ID: 20361342
you can't sorry.
0
 

Author Comment

by:clajo04
ID: 20362363
Okay - not the answer I was hoping for, but very possibly accurate...

If no one can provide a solution in the next couple of days, I will award points to you.

thanks,
-clajo04
0
 
LVL 17

Accepted Solution

by:
Dejan Pažin earned 900 total points
ID: 20364960

Take a look at log4jdbc. Quote: "log4jdbc is a JDBC driver that can log SQL and/or JDBC calls (and optionally SQL timing information) for other JDBC drivers..

http://log4jdbc.sourceforge.net/

And also some other tools, but I belive log4jdbc is the one you need:

http://sourceforge.net/projects/jdbcproxy
http://developer.mimer.se/print_result.tml?typ=2&id=28
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Ready to improve network connectivity? Watch this webinar to learn how SD-WANs and a one-click instant connect tool can boost provisions, deployment, and management of your cloud connection.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This was posted to the Netbeans forum a Feb, 2010 and I also sent it to Verisign. Who didn't help much in my struggles to get my application signed. ------------------------- Start The idea here is to target your cell phones with the correct…
In this post we will learn different types of Android Layout and some basics of an Android App.
Viewers learn about the scanner class in this video and are introduced to receiving user input for their programs. Additionally, objects, conditional statements, and loops are used to help reinforce the concepts. Introduce Scanner class: Importing…
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.
Suggested Courses

719 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question