# File lib/new_relic/agent/threading/agent_thread.rb, line 36 def self.bucket_thread(thread, profile_agent_code) #THREAD_LOCAL_ACCESS if thread.key?(:newrelic_label) profile_agent_code ? :agent : :ignore else state = TransactionState.tl_state_for(thread) if state.in_background_transaction? :background elsif state.in_web_transaction? :request else :other end end end