Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type OptionalInfo ¶
type OptionalInfo struct { // Message is additional message that will be added to Task State. Use nil for empty. Message *string // Healthy indicates if task is healthy (true) or not (false) for unknown pass nil. Healthy *bool }
OptionalInfo contains optional info that could be attached to Task State update.
type Updater ¶
type Updater interface { // Update sends task state update to Mesos agent. It should be a non-blocking // call. Update(mesos.TaskID, mesos.TaskState) // UpdateWithMessage sends task state update with optional fields to Mesos agent. It // should be a non-blocking call. UpdateWithOptions(mesos.TaskID, mesos.TaskState, OptionalInfo) // Acknowledge marks task state update with matching uuid as acknowledged by Mesos agent. Acknowledge([]byte) // GetUnacknowledged returns slice of unacknowledged task statuses. GetUnacknowledged() []executor.Call_Update // Wait continues sending state updates to Mesos agent until all of them are // sent or given duration is exceeded. Wait(time.Duration) error }
Updater is an interface for types responsible for updating task status in Mesos agent. Implementation should handle all the retry logic when an agent is offline.
func BufferedUpdater ¶
BufferedUpdater returns an updater implementation that keeps state updates in a buffered channel (to allow non-blocking calls to the Update function). It will be trying to send buffered state updates in a background goroutine until Wait is called.
Click to show internal directories.
Click to hide internal directories.