Sha256: 420ccd606d9a33d680354339200054fbe8228dadd3ff671453d3b33857f6848e
Contents?: true
Size: 739 Bytes
Versions: 33
Compression:
Stored size: 739 Bytes
Contents
module PlainApm module Extensions module Context STORE_KEY = :plain_apm_extensions_store TRACE_ID_KEY = :trace_id CONTEXT_KEY = :context def self.current Thread.current[STORE_KEY] ||= {} end def self.clear! Thread.current[STORE_KEY] = {} end def self.[](key) current[key] end def self.[]=(key, value) current[key] = value end def self.context current[CONTEXT_KEY] ||= {} end def self.context=(hash) current[CONTEXT_KEY] = hash end def self.trace_id current[TRACE_ID_KEY] end def self.trace_id=(id) current[TRACE_ID_KEY] = id end end end end
Version data entries
33 entries across 33 versions & 1 rubygems