Help us shape the future of Go! Take the 2026 Go Developer Survey

executionclient

package
v0.0.48 Latest Latest
Warning

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

Go to latest
Published: Oct 13, 2026 License: Apache-2.0 Imports: 29 Imported by: 0

Documentation

Overview

Package executionclient implements the private mTLS client and placement adapter for the independently deployed Kubernetes execution provider.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LoadTLSConfig

func LoadTLSConfig(files TLSFiles) (*tls.Config, error)

LoadTLSConfig loads provider trust and client identity from a complete projection.

Types

type Client

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

Client is a bounded client for the private execution-provider gRPC API.

func New

func New(endpoint string, tlsConfig *tls.Config) (*Client, error)

New constructs a production mTLS execution-provider client. Endpoint is a plain host:port authority; URI schemes and alternate resolvers are rejected.

func NewWithTLSFiles added in v0.0.48

func NewWithTLSFiles(endpoint string, files TLSFiles) (*Client, error)

NewWithTLSFiles owns a reloadable connection; invalid material withdraws active authority instead of allowing a stale channel to continue.

func (*Client) AbortReference

func (c *Client) AbortReference(ctx context.Context, req executionenv.ReferenceRequest) error

func (*Client) AcquireRun

AcquireRun acquires one environment-wide run claim.

func (*Client) Attach

Attach obtains current allocation state for an exact environment reference.

func (*Client) CancelCommand

CancelCommand cancels a command after the request has been authorized.

func (*Client) CancelReferenceDelete

func (c *Client) CancelReferenceDelete(ctx context.Context, req executionenv.ReferenceRequest) error

func (*Client) Close

func (c *Client) Close()

Close releases the provider connection.

func (*Client) CommandStatus

CommandStatus queries a command after the request has been authorized.

func (*Client) CommitReference

func (c *Client) CommitReference(ctx context.Context, req executionenv.ReferenceRequest) error

func (*Client) ConfirmReferenceDelete

func (c *Client) ConfirmReferenceDelete(ctx context.Context, req executionenv.ReferenceRequest) error

func (*Client) DeleteRetiredEnvironment

func (c *Client) DeleteRetiredEnvironment(ctx context.Context, ref executionenv.EnvironmentRef, owner executionenv.Owner, expectedPVCUID, operationID string) error

DeleteRetiredEnvironment deletes retained storage after retirement proof.

func (*Client) EnsureTemplate added in v0.0.48

func (c *Client) EnsureTemplate(ctx context.Context, binding, id, revision string, owner executionenv.Owner, operationID string) (executionenv.EnsureEnvironmentResponse, error)

func (*Client) File

File executes one authorized filesystem operation.

func (*Client) FindReferenceIntent

func (c *Client) FindReferenceIntent(ctx context.Context, owner executionenv.Owner, environment executionenv.EnvironmentRef, binding string) (executionenv.ReferenceIntent, error)

func (*Client) Invoke added in v0.0.48

func (c *Client) Invoke(ctx context.Context, method string, args, reply any, opts ...grpc.CallOption) error

Invoke pins the transport for the complete RPC, including its terminal reply.

func (*Client) ListAllReferenceIntents

func (c *Client) ListAllReferenceIntents(ctx context.Context) ([]executionenv.ReferenceIntent, error)

func (*Client) ListExecutionTemplates added in v0.0.48

func (c *Client) ListExecutionTemplates(ctx context.Context) (*executionv1.ListExecutionTemplatesResponse, error)

ListExecutionTemplates returns only operator-authorized display projections.

func (*Client) ListReferenceIntents

func (c *Client) ListReferenceIntents(ctx context.Context, owner executionenv.Owner) ([]executionenv.ReferenceIntent, error)

func (*Client) NewStream added in v0.0.48

func (c *Client) NewStream(ctx context.Context, desc *grpc.StreamDesc, method string, opts ...grpc.CallOption) (grpc.ClientStream, error)

func (*Client) PrepareReferenceDelete

func (c *Client) PrepareReferenceDelete(ctx context.Context, req executionenv.ReferenceRequest) error

func (*Client) RecoverEnvironment

func (c *Client) RecoverEnvironment(ctx context.Context, req executionenv.RetireEnvironmentRequest) error

RecoverEnvironment clears a fence only after the provider verifies exact terminal evidence.

func (*Client) ReleaseReference

func (c *Client) ReleaseReference(ctx context.Context, req executionenv.ReferenceReleaseRequest) error

ReleaseReference releases one durable binding reference.

func (*Client) ReleaseRun

func (c *Client) ReleaseRun(ctx context.Context, req executionenv.RunClaimRequest) error

func (*Client) ReloadTLS added in v0.0.48

func (c *Client) ReloadTLS() error

ReloadTLS publishes a complete, stable identity/trust bundle. Only same-identity renewal under unchanged trust may drain existing RPCs; withdrawal closes them.

func (*Client) RenewRun

func (*Client) ReplaceExecutor

func (c *Client) ReplaceExecutor(ctx context.Context, req executionenv.RetireEnvironmentRequest) error

ReplaceExecutor requests UID-checked administrative executor replacement.

func (*Client) ReserveSuccessor

func (c *Client) ReserveSuccessor(ctx context.Context, req executionenv.ReferenceRequest) error

func (*Client) RetireEnvironment

func (c *Client) RetireEnvironment(ctx context.Context, req executionenv.RetireEnvironmentRequest) error

RetireEnvironment requests administrative retirement.

func (*Client) RevokeEnvironment

func (c *Client) RevokeEnvironment(ctx context.Context, ref executionenv.EnvironmentRef, owner executionenv.Owner, expectedGeneration uint64, operationID string) (uint64, error)

RevokeEnvironment atomically fences active runs and replays a matching operation receipt.

func (*Client) RunTLSReload added in v0.0.48

func (c *Client) RunTLSReload(ctx context.Context, interval time.Duration)

RunTLSReload checks projected credentials until shutdown; renewal is not independent of security-policy publication.

func (*Client) StartCommand

StartCommand executes one foreground command.

func (*Client) ValidateTemplate added in v0.0.48

func (c *Client) ValidateTemplate(ctx context.Context, id, revision string) (*executionv1.ValidateTemplateResponse, error)

ValidateTemplate checks an exact eligible revision without allocation.

type Provider

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

Provider adapts the execution service to server placement binding.

func NewTemplateProvider added in v0.0.48

func NewTemplateProvider(client *Client, id, revision string) (*Provider, error)

NewTemplateProvider pins the deployment default to an exact execution revision.

func (*Provider) AcquireRun

func (*Provider) Applies

func (p *Provider) Applies(ref session.EnvironmentRef) bool

func (*Provider) Bind

Bind allocates the environment for the final session binding.

func (*Provider) CancelReferenceIntentDelete

func (p *Provider) CancelReferenceIntentDelete(ctx context.Context, intent server.ReferenceIntent) error

func (*Provider) CommitReferenceIntent

func (p *Provider) CommitReferenceIntent(ctx context.Context, intent server.ReferenceIntent) error

func (*Provider) ConfirmReferenceIntentDelete

func (p *Provider) ConfirmReferenceIntentDelete(ctx context.Context, intent server.ReferenceIntent) error

func (*Provider) ListExecutionTemplates added in v0.0.48

func (p *Provider) ListExecutionTemplates(ctx context.Context, principal *session.Principal) ([]server.ExecutionTemplateInfo, string, error)

func (*Provider) ListReferenceIntents

func (p *Provider) ListReferenceIntents(ctx context.Context, limit int) ([]server.ReferenceIntent, error)

func (*Provider) PrepareReferenceDelete

func (*Provider) Reattach

Reattach exactly resolves a persisted remote environment for its binding.

func (*Provider) ReserveSuccessor

func (*Provider) ValidatePlacement

func (p *Provider) ValidatePlacement(ctx context.Context) error

ValidatePlacement performs side-effect-free profile preflight.

type TLSFiles

type TLSFiles struct{ CA, Cert, Key, ServerName string }

TLSFiles names the runtime-only mTLS material mounted into mecak8s. TLSFiles names a complete mTLS projection. ServerName explicitly pins the verified DNS identity when the dial address is a local port-forward; empty uses the endpoint hostname for TLS verification.

Jump to

Keyboard shortcuts

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