module ActiveRecord::QueryLogs

def comment

Sets and returns a cached comment if cache_query_log_tags is +true+.
Returns an SQL comment +String+ containing the query log tags.
def comment
  if cache_query_log_tags
    self.cached_comment ||= uncached_comment
  else
    uncached_comment
  end
end