Method: Faye::Engine::Proxy#initialize
- Defined in:
- lib/faye/engines/proxy.rb
#initialize(options) ⇒ Proxy
Returns a new instance of Proxy.
39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 |
# File 'lib/faye/engines/proxy.rb', line 39 def initialize() super() = @connections = {} @interval = [:interval] || INTERVAL @timeout = [:timeout] || TIMEOUT engine_class = [:type] || Memory @engine = engine_class.create(self, ) bind :close do |client_id| EventMachine.next_tick { flush_connection(client_id) } end debug('Created new engine: ?', ) end |