vessel

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Jun 21, 2025 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	// contains filtered or unexported fields
}

func New

func New(nc *nats.Conn) *Client

func (*Client) CreateWorker

func (c *Client) CreateWorker(ctx context.Context, s Service) (uint64, error)

func (*Client) DestroyWorker

func (c *Client) DestroyWorker(ctx context.Context, s Service, workerID uint64) error

func (*Client) Discover

func (c *Client) Discover(ctx context.Context, serviceName string, outputCh chan<- Service) error

func (*Client) Execute

func (c *Client) Execute(ctx context.Context, s Service, filePath string, args []string, stdin io.ReadCloser, stdout io.WriteCloser) (int64, error)

func (*Client) GetInfo

func (c *Client) GetInfo(ctx context.Context, id ID) (Service, error)

func (*Client) GetWorker

func (c *Client) GetWorker(ctx context.Context, s Service, workerID uint64) (ID, error)

type Endpoint

type Endpoint struct {
	// contains filtered or unexported fields
}

type Error

type Error struct {
	Code    string
	Message string
}

func (*Error) Error

func (e *Error) Error() string

type ID

type ID struct {
	// contains filtered or unexported fields
}

func NewID

func NewID(serviceName, id string) ID

func ParseID

func ParseID(s string) (ID, error)

func (ID) ServiceName

func (i ID) ServiceName() string

func (ID) String

func (i ID) String() string

type Service

type Service struct {
	ID        ID
	Metadata  map[string]string
	Endpoints map[string]Endpoint
}

Jump to

Keyboard shortcuts

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