Sha256: 7e1354f89eb3adde8714f8f58e453c444a8e5e92b582938337512c3c72942253
Contents?: true
Size: 559 Bytes
Versions: 2
Compression:
Stored size: 559 Bytes
Contents
require 'timber/util' require 'timber/event' module Timber module Events # @private class SQLQuery < Timber::Event attr_reader :sql, :duration_ms, :message def initialize(attributes) @sql = attributes[:sql] @duration_ms = attributes[:duration_ms] @message = attributes[:message] end def to_hash { sql_query_executed: Util::NonNilHashBuilder.build do |h| h.add(:sql, sql) h.add(:duration_ms, duration_ms) end } end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
timber-3.0.1 | lib/timber/events/sql_query.rb |
timber-3.0.0 | lib/timber/events/sql_query.rb |