module ActiveRecord::ConnectionAdapters::QueryCache

def cache_notification_info(sql, name, binds)

provide custom cache information.
Database adapters can override this method to
def cache_notification_info(sql, name, binds)
  {
    sql: sql,
    binds: binds,
    type_casted_binds: -> { type_casted_binds(binds) },
    name: name,
    connection: self,
    cached: true
  }
end