Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ResourceFields ¶
type ResourceFields struct { *ResourceFieldsCommon Ctx context.Context DockerClient dockerapi.DockerClient NetworkUtils networkutils.NetworkUtils }
ResourceFields is the list of fields required for creation of task resources
type ResourceFieldsCommon ¶
type ResourceFieldsCommon struct { IOUtil ioutilwrapper.IOUtil ASMClientCreator asmfactory.ClientCreator SSMClientCreator ssmfactory.SSMClientCreator FSxClientCreator fsxfactory.FSxClientCreator S3ClientCreator s3factory.S3ClientCreator CredentialsManager credentials.Manager EC2InstanceID string }
type TaskResource ¶
type TaskResource interface { // SetDesiredStatus sets the desired status of the resource SetDesiredStatus(resourcestatus.ResourceStatus) // GetDesiredStatus gets the desired status of the resource GetDesiredStatus() resourcestatus.ResourceStatus // SetKnownStatus sets the desired status of the resource SetKnownStatus(resourcestatus.ResourceStatus) // GetKnownStatus gets the desired status of the resource GetKnownStatus() resourcestatus.ResourceStatus // SetCreatedAt sets the timestamp for resource's creation time SetCreatedAt(time.Time) // GetCreatedAt sets the timestamp for resource's creation time GetCreatedAt() time.Time // Create performs resource creation Create() error // Cleanup performs resource cleanup Cleanup() error // GetName returns the unique name of the resource GetName() string // DesiredTerminal returns true if remove is in terminal state DesiredTerminal() bool // KnownCreated returns true if resource state is CREATED KnownCreated() bool // TerminalStatus returns the last transition state of the resource TerminalStatus() resourcestatus.ResourceStatus // NextKnownState returns resource's next state NextKnownState() resourcestatus.ResourceStatus // ApplyTransition calls the function required to move to the specified status ApplyTransition(resourcestatus.ResourceStatus) error // SteadyState returns the transition state of the resource defined as "ready" SteadyState() resourcestatus.ResourceStatus // SetAppliedStatus sets the applied status of resource and returns whether // the resource is already in a transition SetAppliedStatus(status resourcestatus.ResourceStatus) bool // GetAppliedStatus gets the applied status of resource GetAppliedStatus() resourcestatus.ResourceStatus // StatusString returns the string of the resource status StatusString(status resourcestatus.ResourceStatus) string // GetTerminalReason returns string describing why the resource failed to // provision GetTerminalReason() string // DependOnTaskNetwork shows whether the resource creation needs task network setup beforehand DependOnTaskNetwork() bool // GetContainerDependencies returns dependent containers for a status GetContainerDependencies(resourcestatus.ResourceStatus) []apicontainer.ContainerDependency // BuildContainerDependency adds a new dependency container and its satisfied status BuildContainerDependency(containerName string, satisfied apicontainerstatus.ContainerStatus, dependent resourcestatus.ResourceStatus) // Initialize will initialize the resource fields of the resource Initialize(res *ResourceFields, taskKnownStatus apitaskstatus.TaskStatus, taskDesiredStatus apitaskstatus.TaskStatus) json.Marshaler json.Unmarshaler }
TaskResource is a wrapper for task level resource methods we need
type TransitionDependenciesMap ¶
type TransitionDependenciesMap map[resourcestatus.ResourceStatus]TransitionDependencySet
TransitionDependenciesMap is a map of the dependent resource status to other dependencies that must be satisfied.
type TransitionDependencySet ¶
type TransitionDependencySet struct { // ContainerDependencies is the set of containers on which a transition is // dependent. ContainerDependencies []apicontainer.ContainerDependency `json:"ContainerDependencies"` }
TransitionDependencySet contains dependencies that impact transitions of resources.
Source Files ¶
Directories ¶
Path | Synopsis |
---|---|
control/factory/mock
Package mock_cgroup1 is a generated GoMock package.
|
Package mock_cgroup1 is a generated GoMock package. |
control/factory/mock_factory
Package mock_factory is a generated GoMock package.
|
Package mock_factory is a generated GoMock package. |
control/mock_control
Package mock_control is a generated GoMock package.
|
Package mock_control is a generated GoMock package. |
Package mock_taskresource is a generated GoMock package.
|
Package mock_taskresource is a generated GoMock package. |
Click to show internal directories.
Click to hide internal directories.