Module: DbSwitch::ThreadVariables

Included in:
ActiveRecordBase, LogSubscriber
Defined in:
lib/db-switch/thread_variables.rb

Instance Method Summary collapse

Instance Method Details

#db_switch_connection_nameObject



3
4
5
# File 'lib/db-switch/thread_variables.rb', line 3

def db_switch_connection_name
  Thread.current[:db_switch_connection_name]
end

#db_switch_connection_name=(value) ⇒ Object



7
8
9
# File 'lib/db-switch/thread_variables.rb', line 7

def db_switch_connection_name=(value)
  Thread.current[:db_switch_connection_name] = value
end