socket

package
v2.0.0-alpha23 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 17, 2020 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewSocketServer

func NewSocketServer(ls net.Listener, tout time.Duration) worker.Factory

NewSocketServer returns Factory attached to a given socket listener. tout specifies for how long factory should serve for incoming relay connection

Types

type Factory

type Factory struct {
	ErrCh chan error
	// contains filtered or unexported fields
}

Factory connects to external stack using socket server.

func (*Factory) Close

func (f *Factory) Close(ctx context.Context) error

Close socket factory and underlying socket connection.

func (*Factory) SpawnWorker

func (f *Factory) SpawnWorker(cmd *exec.Cmd) (worker.BaseProcess, error)

func (*Factory) SpawnWorkerWithContext

func (f *Factory) SpawnWorkerWithContext(ctx context.Context, cmd *exec.Cmd) (worker.BaseProcess, error)

SpawnWorker creates Process and connects it to appropriate relay or returns error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL