# Functions
ConvertCommandToShellScript writes a POSIX shell script to a StringWriter that causes a process to be launched in the way encoded in a Command message.
GetResultAndGRPCCodeFromExecuteResponse converts an ExecuteResponse to a pair of strings that describe the execution outcome.
LaunchWorkerThread launches a single routine that uses a build client to repeatedly synchronizes against the scheduler, requesting a task to execute.
NewBuildClient creates a new BuildClient instance that is set to the initial state (i.e., being idle).
NewCachingBuildExecutor creates an adapter for BuildExecutor that stores action results in the Action Cache (AC) if they may be cached.
NewCleanBuildDirectoryCreator is an adapter for BuildDirectoryCreator that upon acquisition and release calls into a Cleaner.
NewCompletedActionLoggingBuildExecutor returns a new completedActionLoggingBuildExecutor that will transmit CompletedActions to an external server for real-time analysis of REv2 Action metadata using a CompletedActionLogger.
NewCostComputingBuildExecutor wraps an existing BuildExecutor, adding the computed cost of the action to the prepopulated AuxiliaryMetadata field of the ActionResult.
NewDefaultExecuteResponse creates an ExecuteResponse message that contains all fields that BuildExecutor should set by default.
NewFilePoolStatsBuildExecutor creates a decorator for BuildExecutor that annotates ExecuteResponses to contain usage statistics of the FilePool.
NewLocalBuildExecutor returns a BuildExecutor that executes build steps on the local system.
NewLoggingBuildExecutor wraps an existing BuildExecutor, adding basic logging.
NewMetricsBuildExecutor creates a decorator for BuildExecutor that exposes the statistics stored in ExecutedActionMetadata as Prometheus metrics.
NewNaiveBuildDirectory creates a BuildDirectory that is backed by a simple filesystem.Directory with all of the operations implemented in a naive way.
NewNoopBuildExecutor creates a BuildExecutor that always returns an error message when attempting to execute an action.
NewOutputHierarchy creates a new OutputHierarchy that uses the working directory and the output paths specified in an REv2 Command message.
NewPrefetchingBuildExecutor creates a decorator for BuildExecutor that as the action gets executed, prefetches files that are part of the action's input root from the Content Addressable Storage (CAS).
NewRemoteCompletedActionLogger returns a new RemoteCompletedActionLogger with a predefined maximum capacity of stored messages.
NewRootBuildDirectoryCreator is a BuildDirectoryCreator that repeatedly hands out a single directory present on the current system.
NewSharedBuildDirectoryCreator is an adapter for BuildDirectoryCreator that causes build actions to be executed inside a subdirectory within the build directory, as opposed to inside the build directory itself.
NewStorageFlushingBuildExecutor is an adapter for BuildExecutor that calls a callback after every operation.
NewTestInfrastructureFailureDetectingBuildExecutor is a decorator for BuildExecutor that counts the number of consecutive actions that generated one or more "test.infrastructure_failure" output files.
NewTestInfrastructureFailureShutdownState creates a new TestInfrastructureFailureShutdownState that is in the initial state, where no infrastructure failures have occurred.
NewTimestampedBuildExecutor creates a decorator for BuildExecutor that augments the ActionResult that is part of the ExecuteResponse with ExecutedActionMetadata.
NewTracingBuildExecutor is a decorator for BuildExecutor that creates an OpenTelemetry trace span for every action that is executed.
NewVirtualBuildDirectory creates a BuildDirectory that is backed by a virtual.PrepopulatedDirectory.
# Structs
BuildClient is a client for the Remote Worker protocol.
OutputHierarchy is used by LocalBuildExecutor to track output directories and files that are expected to be generated by the build action.
The RemoteCompletedActionLogger type is used to store and send CompletedActions for a completedActionLoggingBuildExecutor.
TestInfrastructureFailureShutdownState keeps track of whether a group of worker threads have shut down, due to an excessive number of consecutive tests failing due to infrastructure failures on a single worker thread.
# Interfaces
BuildDirectory is a directory that may be used for the purpose of running build actions.
BuildDirectoryCreator is used by LocalBuildExecutor to obtain build directories in which build actions are executed.
BuildExecutor is the interface for the ability to run Bazel execute requests and yield an execute response.
The CompletedActionLogger can be used to record CompletedActions for realtime or post-build analysis in a remote service.
ParentPopulatableDirectory contains a subset of the methods of filesystem.Directory that are required for creating the parent directories of output files of a build action.
UploadableDirectory is a directory that can be uploaded into the Content Addressable Storage.
# Type aliases
StorageFlusher is a callback that is invoked by NewStorageFlushingBuildExecutor to flush contents to storage.