module Transport

A per-request transport with independent control and full-duplex body channels.

Nested Classes and Modules

class Endpoint

One endpoint of an execution transport.

Definitions

def self.pair

Create connected client and worker transport endpoints.

Signature

returns Array(Endpoint, Array(IO))

The client endpoint and worker IO objects.

Implementation

def self.pair
	client_control, worker_control = Socket.pair(:UNIX, :STREAM, 0)
	client_body, worker_body = Socket.pair(:UNIX, :STREAM, 0)
	
	client = Endpoint.new(client_control, client_body)
	worker = [worker_control, worker_body]
	
	return client, worker
end