Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewClient ¶
func NewClient( base remoteexecution.Client[*model_executewithstorage_pb.Action, *model_core_pb.WeakDecodableReference, *model_core_pb.WeakDecodableReference], ) remoteexecution.Client[*Action[object.GlobalReference], model_core.Decodable[object.LocalReference], model_core.Decodable[object.LocalReference]]
NewClient 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.
func NewExecutor ¶
func NewExecutor( base remoteworker.Executor[*Action[object.GlobalReference], model_core.Decodable[object.LocalReference], model_core.Decodable[object.LocalReference]], ) remoteworker.Executor[*model_executewithstorage_pb.Action, *model_core_pb.WeakDecodableReference, *model_core_pb.WeakDecodableReference]
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.
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.