How to get more detailed information about the datasource and connection apart from trace and spy logging ?

Solution Unverified - Updated -

Issue

  • The SQL Trace and Spy logging does not provide more detailed information about the connection wrapper and the connection id.
  • We have connection tracing on which give us the following, but it would be nice if the output gave some sort of connection identifier to be able to see which connection each line is referring to. With a loaded app that has many connections going, it is impossible to correlate the data without some sort of connection id. Is there any way to do this?
2015-05-01 08:05:51,703 ERROR [test.scheduler.TestStartup] (Thread-184) TestStartup starting....
2015-05-01 08:05:51,984 DEBUG [jboss.jdbc.spy] (MSC service thread 1-1) java:jboss/datasources/TestDS [Connection] prepareStatement(select permissionid, constant from testtable)
2015-05-01 08:05:51,990 DEBUG [jboss.jdbc.spy] (MSC service thread 1-1) java:jboss/datasources/TestDS [PreparedStatement] executeQuery()
2015-05-01 08:05:52,006 DEBUG [jboss.jdbc.spy] (MSC service thread 1-1) java:jboss/datasources/TestDS [ResultSet] next()
2015-05-01 08:05:52,006 DEBUG [jboss.jdbc.spy] (MSC service thread 1-1) java:jboss/datasources/TestDS [ResultSet] getString(1)
2015-05-01 08:05:52,006 DEBUG [jboss.jdbc.spy] (MSC service thread 1-1) java:jboss/datasources/TestDS [ResultSet] getString(2)
2015-05-01 08:05:52,021 DEBUG [jboss.jdbc.spy] (MSC service thread 1-1) java:jboss/datasources/TestDS [ResultSet] next()
2015-05-01 08:05:52,021 DEBUG [jboss.jdbc.spy] (MSC service thread 1-1) java:jboss/datasources/TestDS [ResultSet] getString(1)
2015-05-01 08:05:52,021 DEBUG [jboss.jdbc.spy] (MSC service thread 1-1) java:jboss/datasources/TestDS [ResultSet] getString(2)
2015-05-01 08:05:52,021 DEBUG [jboss.jdbc.spy] (MSC service thread 1-1) java:jboss/datasources/TestDS [ResultSet] next()

Environment

  • Red Hat JBoss Enterprise Application Platform (EAP)
    • 6.x

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content