Method: ActionCable::Connection::Base#initialize

Defined in:
actioncable/lib/action_cable/connection/base.rb

#initialize(server, env, coder: ActiveSupport::JSON) ⇒ Base

Returns a new instance of Base.



67
68
69
70
71
72
73
74
75
76
77
78
79
# File 'actioncable/lib/action_cable/connection/base.rb', line 67

def initialize(server, env, coder: ActiveSupport::JSON)
  @server, @env, @coder = server, env, coder

  @worker_pool = server.worker_pool
  @logger = new_tagged_logger

  @websocket      = ActionCable::Connection::WebSocket.new(env, self, event_loop)
  @subscriptions  = ActionCable::Connection::Subscriptions.new(self)
  @message_buffer = ActionCable::Connection::MessageBuffer.new(self)

  @_internal_subscriptions = nil
  @started_at = Time.now
end