Class: Green::ActiveRecord

Inherits:
Green
  • Object
show all
Defined in:
lib/green/activerecord.rb

Constant Summary

Constants inherited from Green

ERRORS, MAIN, VERSION

Instance Attribute Summary

Attributes inherited from Green

#callbacks, #f

Instance Method Summary collapse

Methods inherited from Green

#alive?, #callback, current, hub, init, #join, list, list_hash, main, make_hub, sleep, spawn, #start, thread_locals, timeout

Methods included from GreenMethods

#[], #[]=, #kill, #locals, #schedule, #switch, #throw

Constructor Details

#initializeActiveRecord

Returns a new instance of ActiveRecord.



16
17
18
19
# File 'lib/green/activerecord.rb', line 16

def initialize
  super
  callback { ::ActiveRecord::Base.clear_active_connections! }
end