Method: OneApm::TransactionState.tl_state_for
- Defined in:
- lib/one_apm/transaction/transaction_state.rb
.tl_state_for(thread) ⇒ Object
This method should only be used by TransactionState for access to the current thread’s state or to provide read-only accessors for other threads
If ever exposed, this requires additional synchronization
18 19 20 21 22 23 24 25 26 27 |
# File 'lib/one_apm/transaction/transaction_state.rb', line 18 def self.tl_state_for(thread) state = thread[:oneapm_transaction_state] if state.nil? state = TransactionState.new thread[:oneapm_transaction_state] = state end state end |