Module: Async::HTTY::Environment::Server

Defined in:
lib/async/htty/environment/server.rb

Overview

An async-service environment module for HTTY transport. Include this (or let Lively::Environment::Application include it) to replace Falcon with an HTTY server in the service lifecycle.

Instance Method Summary collapse

Instance Method Details

#container_optionsObject

Do not restart after the HTTY session ends. Unlike a TCP server, there is nothing to reconnect to once stdin/stdout closes.



19
20
21
# File 'lib/async/htty/environment/server.rb', line 19

def container_options
	{count: 1, restart: false}
end

#service_classObject

Use the HTTY service server instead of Falcon’s.



25
26
27
# File 'lib/async/htty/environment/server.rb', line 25

def service_class
	Async::HTTY::Service::Server
end