#981 ✓resolved
Dan Kubb (dkubb)

DO JDBC query logging differences causes spec failure w/dm-core

Reported by Dan Kubb (dkubb) | July 19th, 2009 @ 01:17 AM | in 0.10.0

When DO is used with JRuby, the logging output is different for queries than when DO is used with MRI. This causes some spec failures in dm-core, since it compares the logged query with the expected query. Here is the specific failure as shown in the (new) CI system:

http://ci.datamapper.org/viewLog.html?buildId=191&tab=buildResu...

There are two problems:

  • The prepared statement object is being stringified, rather than the actual query with the bind values merged.
  • The query time is not being logged. The number of seconds should be displayed in as high resolution as possible. The current MRI driver shows as many as 6 digits after the decimal point. This is very useful for debugging and identifying slow queries for indexing/optimizations.

From what I can tell the query time not being logged occurs with all queries, while the prepared statement stringification happens only in specific cases.

Comments and changes to this ticket

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

People watching this ticket

Referenced by

Pages