rewrapper

package
v0.0.0-...-e01adf3 Latest Latest
Warning

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

Go to latest
Published: Jan 15, 2025 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Overview

Package rewrapper contains the rewrapper logic for converting a command via CLI to a gRPC request to the RE Proxy.

Index

Constants

View Source
const (
	// WrapperOverheadKey is the key for the wrapper overhead metric passed to the proxy.
	WrapperOverheadKey = "WrapperOverhead"
)

Variables

This section is empty.

Functions

func RunCommand

func RunCommand(ctx context.Context, dialTimeout time.Duration, proxy Proxy, cmd []string, opts *CommandOptions) (*ppb.RunResponse, error)

RunCommand runs a command through the RE proxy.

Types

type CommandOptions

type CommandOptions struct {
	CommandID                    string
	InvocationID                 string
	CorrelatedInvocationsID      string
	ToolName                     string
	Labels                       map[string]string
	ExecRoot                     string
	WorkDir                      string
	OutputFiles                  []string
	OutputDirectories            []string
	Inputs                       []string
	VirtualInputs                string
	ToolchainInputs              []string
	InputListPaths               []string
	OutputListPaths              []string
	EnvVarAllowlist              []string
	ExecTimeout                  time.Duration
	ReclientTimeout              time.Duration
	ExecStrategy                 string
	Compare                      bool
	Platform                     map[string]string
	RemoteAcceptCache            bool
	RemoteUpdateCache            bool
	DownloadOutputs              bool
	DownloadRegex                string
	EnableAtomicDownloads        bool
	LogEnvironment               bool
	StartTime                    time.Time
	NumRetriesIfMismatched       int
	NumLocalReruns               int
	NumRemoteReruns              int
	FailOnMismatch               bool
	LocalWrapper                 string
	RemoteWrapper                string
	PreserveSymlink              bool
	CanonicalizeWorkingDir       bool
	ActionLog                    string
	PreserveUnchangedOutputMtime bool
}

CommandOptions contains command execution options passed to the rewrapper.

type Proxy

type Proxy interface {
	RunCommand(context.Context, *ppb.RunRequest, ...grpc.CallOption) (*ppb.RunResponse, error)
}

Proxy is the interface of hte RE Proxy API.

Jump to

Keyboard shortcuts

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