Module: Envoy::Client

Defined in:
lib/envoy/client/trunk.rb,
lib/envoy/client/channel.rb

Defined Under Namespace

Modules: Channel, Trunk

Class Method Summary collapse

Class Method Details

.run(options = {}) ⇒ Object



22
23
24
25
26
27
28
29
30
31
# File 'lib/envoy/client/channel.rb', line 22

def self.run (options = {})
  unless EM.reactor_running?
    EM.run do
      EM.add_periodic_timer(0.1) do
        $reloader.(0)
      end
      EM.connect options[:server_host], options[:server_port], self, options
    end
  end
end