Documentation ¶
Index ¶
- Variables
- func ContainerAttachable(pod, container string) watchtools.ConditionFunc
- func ContainerReady(pod, container string, init, isTTY bool) watchtools.ConditionFunc
- func ContainerStreamable(pod, container string) watchtools.ConditionFunc
- func InitContainerAttachable(pod, container string) watchtools.ConditionFunc
- func InitContainerStreamable(pod, container string) watchtools.ConditionFunc
- func IsQueued(runName string) watchtools.ConditionFunc
- func LogQueuePosition(runName string) watchtools.ConditionFunc
- func PodHandlerWrapper(name string, h podHandler) watchtools.ConditionFunc
- func Reconciled(obj reconcilable) watchtools.ConditionFunc
- func RunConnectable(name string, isTTY bool) watchtools.ConditionFunc
- func WorkspaceReady() watchtools.ConditionFunc
Constants ¶
This section is empty.
Variables ¶
var ( ErrWorkspaceFailed = errors.New("workspace is in a failure state") ErrWorkspaceDeletion = errors.New("workspace is currently being deleted") )
var ErrResourceUnexpectedlyDeleted = errors.New("resource unexpectedly deleted")
var (
ErrRunFailed = errors.New("run failed")
)
var PrematurelySucceededPodError = errors.New("pod prematurely succeeded")
Functions ¶
func ContainerAttachable ¶
func ContainerAttachable(pod, container string) watchtools.ConditionFunc
ContainerAttachable is an event handler that returns true if a pod container's TTY can be attached to, i.e. the container has started and is ready to handshake (therefore it should not have finished yet).
func ContainerReady ¶
func ContainerReady(pod, container string, init, isTTY bool) watchtools.ConditionFunc
ContainerReady returns an appropriate event handler for determining when pod is ready for attaching to or streaming from.
func ContainerStreamable ¶
func ContainerStreamable(pod, container string) watchtools.ConditionFunc
ContainerStreamable is an event handler that returns true if the pod Container's logs can be streamed, i.e. the container has at least started
func InitContainerAttachable ¶
func InitContainerAttachable(pod, container string) watchtools.ConditionFunc
InitContainerAttachable is an event handler that returns true if a pod initContainer's TTY can be attached to, i.e. the init container has started and is ready to handshake (therefore it should not have finished yet).
func InitContainerStreamable ¶
func InitContainerStreamable(pod, container string) watchtools.ConditionFunc
InitContainerStreamable is an event handler that returns true if the pod initContainer's logs can be streamed, i.e. the init container has at least started
func LogQueuePosition ¶
func LogQueuePosition(runName string) watchtools.ConditionFunc
Log queue position until run is at front of queue
func PodHandlerWrapper ¶
func PodHandlerWrapper(name string, h podHandler) watchtools.ConditionFunc
PodHandlerWrapper is a wrapper for creating handlers for pod events
func Reconciled ¶ added in v0.0.3
func Reconciled(obj reconcilable) watchtools.ConditionFunc
Handler that returns true when a resource has been reconciled. Reconciled here means it has been reconciled at least once. This handler is useful to determine if an operator is functioning.
func RunConnectable ¶ added in v0.0.7
func RunConnectable(name string, isTTY bool) watchtools.ConditionFunc
RunConnectable returns true if the run indicates its container can be connected to. If isTTY is true then the container must be running and must not have completed. If isTTY is false then the container can either be running or have completed (because its logs can be retrieved).
func WorkspaceReady ¶ added in v0.0.7
func WorkspaceReady() watchtools.ConditionFunc
WorkspaceReady returns true when a workspace's ready condition is true. An error is returned if the ready condition is false with a failure reason or it a deletion reason (its undergoing deletion). Any other reason returns false.
Types ¶
This section is empty.