client

package
v0.0.2-alpha.3 Latest Latest
Warning

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

Go to latest
Published: Feb 11, 2026 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

Functions

func NewEmbeddedClient

func NewEmbeddedClient(manager manager.RunnerManager) *embeddedClient

Types

type RunnerClient

type RunnerClient interface {
	// GetPrimaryServerUID returns the primary server UID.
	GetPrimaryServerUID(ctx context.Context) (int64, error) //NOTE: temporary

	// Config returns the runner config for the server.
	Config(ctx context.Context, serverUID int64) (*types.RunnerConfig, error)

	// Request requests the next available deployment for execution.
	Request(ctx context.Context) (*types.Deployment, error)

	// Accept accepts a deployment for execution.
	Accept(ctx context.Context, deployment *types.Deployment) error

	// Init returns all the information for the deployment to be executed.
	Init(ctx context.Context, deploymentID int64) (*pipeline.RunnerContext, error)

	// Update updates the deployment with new information.
	Update(ctx context.Context, deployment *types.Deployment) error

	// Watch watches for deployment cancellation events.
	Watch(ctx context.Context, deploymentID int64) (bool, error)

	// Stream streams real time logs to backend
	Stream(ctx context.Context, deploymentID int64, logs []*types.LogLine) error

	// Upload uploads the full logs to server
	Upload(ctx context.Context, deploymentID int64, logs []*types.LogLine) error

	//Metrics
	// UploadMetrics uploads the full metrics to server
	UploadMetrics(ctx context.Context, metrics []*types.AppMetrics) error
}

func ProvideRunnerClient

func ProvideRunnerClient(manager manager.RunnerManager) RunnerClient

Jump to

Keyboard shortcuts

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