gphat/dbix-class-querylog — pull request #1 by DrHyde (2012-05-10 16:55:07+00:00)
Title: This small patch makes it easier to subclass DBIx::Class::QueryLog

My motivation for this is that I have a subclass of DBIx::Class::QueryLog, called DBIx::Class::QueryLog::WithStackTrace, which adds a perl stack trace to objects in the log to make it easier to figure out where in my application the queries are coming from. However, because my query_start() method is just a thin wrapper around yours, it uses your DBIx::Class::QueryLog::Query class. For now, I'm "monkey-patching" that class by just shoving a 'stacktrace' key into its underlying hash, but this is ... icky.

If you apply this patch, then my subclass will be able to override the new query_class() method, and I'll be able to properly subclass DBIx::Class::QueryLog::Query.