calls

package
v0.0.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 13, 2017 License: Apache-2.0 Imports: 3 Imported by: 22

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CallNoData added in v0.0.4

func CallNoData(ctx context.Context, caller Caller, call *executor.Call) error

CallNoData is a convenience func that executes the given Call using the provided Caller and always drops the response data.

func Executor

func Executor(id string) executor.CallOpt

Executor sets a executor.Call's ExecutorID

func Framework

func Framework(id string) executor.CallOpt

Framework sets a executor.Call's FrameworkID

func Message

func Message(data []byte) *executor.Call

Message returns an executor call with the given parameters.

func Subscribe

func Subscribe(unackdTasks []mesos.TaskInfo, unackdUpdates []executor.Call_Update) *executor.Call

Subscribe returns an executor call with the given parameters.

func Update

func Update(status mesos.TaskStatus) *executor.Call

Update returns an executor call with the given parameters.

Types

type Caller added in v0.0.4

type Caller interface {
	// Call issues a call to Mesos and properly manages call-specific HTTP response headers & data.
	Call(context.Context, *executor.Call) (mesos.Response, error)
}

Caller is the public interface this framework scheduler's should consume

type CallerFunc added in v0.0.4

type CallerFunc func(context.Context, *executor.Call) (mesos.Response, error)

CallerFunc is the functional adaptation of the Caller interface

func (CallerFunc) Call added in v0.0.4

func (f CallerFunc) Call(ctx context.Context, c *executor.Call) (mesos.Response, error)

Call implements the Caller interface for CallerFunc

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL