Documentation ¶
Index ¶
- Constants
- Variables
- func ExecDir(targetDir string) string
- type ArtifactCachedBuildFailed
- type ArtifactDownloadError
- type ArtifactInstallError
- type ArtifactResolver
- type ArtifactSetupErrors
- type ArtifactSetuper
- type BuildError
- type Configurable
- type ExecutorSetupError
- type ProgressReportError
- type RuntimeInUseError
- type Setup
- type Setuper
- type Targeter
Constants ¶
const MaxConcurrency = 5
MaxConcurrency is maximum number of parallel artifact installations
Variables ¶
var NotInstalledError = errs.New("Runtime is not completely installed.")
NotInstalledError is an error returned when the runtime is not completely installed yet.
Functions ¶
Types ¶
type ArtifactCachedBuildFailed ¶
type ArtifactCachedBuildFailed struct { *errs.WrapperError Artifact *buildplan.Artifact }
ArtifactCachedBuildFailed designates an error due to a build for an artifact that failed and has been cached
type ArtifactDownloadError ¶
type ArtifactDownloadError struct {
*errs.WrapperError
}
ArtifactDownloadError designates an error downloading an artifact.
type ArtifactInstallError ¶
type ArtifactInstallError struct {
*errs.WrapperError
}
ArtifactInstallError designates an error installing a downloaded artifact.
type ArtifactResolver ¶
type ArtifactSetupErrors ¶
type ArtifactSetupErrors struct {
// contains filtered or unexported fields
}
ArtifactSetupErrors combines all errors that can happen while installing artifacts in parallel
func (*ArtifactSetupErrors) Error ¶
func (a *ArtifactSetupErrors) Error() string
func (*ArtifactSetupErrors) Errors ¶
func (a *ArtifactSetupErrors) Errors() []error
Errors returns the individual error messages collected from all failing artifact installations
func (*ArtifactSetupErrors) LocalizedError ¶
func (a *ArtifactSetupErrors) LocalizedError() string
UserError returns a message including all user-facing sub-error messages
func (*ArtifactSetupErrors) Unwrap ¶
func (a *ArtifactSetupErrors) Unwrap() []error
type ArtifactSetuper ¶
type ArtifactSetuper interface { EnvDef(tmpInstallDir string) (*envdef.EnvironmentDefinition, error) Unarchiver() unarchiver.Unarchiver }
ArtifactSetuper is the interface for an implementation of artifact setup functions These need to be specialized for each BuildEngine type
type BuildError ¶
type BuildError struct {
*locale.LocalizedError
}
BuildError designates a recipe build error.
type Configurable ¶
type ExecutorSetupError ¶
type ExecutorSetupError struct {
*errs.WrapperError
}
type ProgressReportError ¶
type ProgressReportError struct {
*errs.WrapperError
}
ProgressReportError designates an error in the event handler for reporting progress.
type RuntimeInUseError ¶
type RuntimeInUseError struct { *locale.LocalizedError Processes []*graph.ProcessInfo }
type Setup ¶
type Setup struct {
// contains filtered or unexported fields
}
func New ¶
func New(target Targeter, eventHandler events.Handler, auth *authentication.Auth, an analytics.Dispatcher, cfg Configurable, out output.Outputer, svcm *model.SvcModel) *Setup
New returns a new Setup instance that can install a Runtime locally on the machine.
type Setuper ¶
type Setuper interface { // DeleteOutdatedArtifacts deletes outdated artifact as best as it can DeleteOutdatedArtifacts(*buildplan.ArtifactChangeset, store.StoredArtifactMap, store.StoredArtifactMap) error }
type Targeter ¶
type Targeter interface { CommitUUID() strfmt.UUID Name() string Owner() string Dir() string Trigger() target.Trigger ProjectDir() string // ReadOnly communicates that this target should only use cached runtime information (ie. don't check for updates) ReadOnly() bool // InstallFromDir communicates that this target should only install artifacts from the given directory (i.e. offline installer) InstallFromDir() *string }