executewithstorage

package
v0.0.0-...-82353ca Latest Latest
Warning

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

Go to latest
Published: Jan 14, 2026 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewExecutor

NewExecutor creates a decorator for the remote worker executor that makes it simpler to run actions on workers that make use of the "executewithstorage" protocol (i.e., workers that rely on actions, execution events, and results to be backed by object storage).

The advantage of using this decorator is that the caller can use native types for decodable references, as opposed to sending and receiving their Protobuf message equivalents.

func NewNamespaceAddingClient

NewNamespaceAddingClient creates a decorator for a remote execution client that can add a namespace (e.g., instance name) to any outgoing execution requests. This decorator can be used to abstract away the notion of instance names in contexts where local object references are sufficient.

func NewObjectExportingClient

func NewObjectExportingClient[TInternal, TExternal any](
	base remoteexecution.Client[*Action[TExternal], model_core.Decodable[TExternal], model_core.Decodable[TExternal]],
	exporter model_core.ObjectExporter[TInternal, TExternal],
) remoteexecution.Client[*Action[TInternal], model_core.Decodable[TInternal], model_core.Decodable[TInternal]]

NewObjectExportingClient creates a decorator for the remote execution client that converts references of actions, execution events and results from one reference format to another.

This decorator can be used to force flushing of objects that only reside in local memory to storage, so that the worker executing the action has access to them as well.

func NewProtoClient

NewProtoClient creates a decorator for the remote execution client that makes it simpler to run actions on workers that make use of the "executewithstorage" protocol (i.e., workers that rely on actions, execution events, and results to be backed by object storage).

The advantage of using this decorator is that the caller can use native types for decodable references, as opposed to sending and receiving their Protobuf message equivalents.

Types

type Action

type Action[TReference any] struct {
	Reference model_core.Decodable[TReference]
	Encoders  []*model_encoding_pb.BinaryEncoder
	Format    *model_core_pb.ObjectFormat
}

Action that a client wants to run on a worker. The actual definition of the action is stored in an object.

In addition to the reference, this struct contains the encoders that the client used to create the object, allowing the worker to decode it. The format needs to be provided so that the worker can reject misrouted requests.

Jump to

Keyboard shortcuts

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