Documentation ¶
Overview ¶
Package executor includes a mesos executor, which contains a kuberlete as its member to manage containers.
Index ¶
- func ListenAndServeKubeletServer(host HostInterface, address net.IP, port uint, enableDebuggingHandlers bool, ...) error
- type FlushWriter
- type HostInterface
- type KubernetesExecutor
- func (k *KubernetesExecutor) Disconnected(driver mesos.ExecutorDriver)
- func (k *KubernetesExecutor) Error(driver mesos.ExecutorDriver, message string)
- func (k *KubernetesExecutor) FrameworkMessage(driver mesos.ExecutorDriver, message string)
- func (k *KubernetesExecutor) KillTask(driver mesos.ExecutorDriver, taskId *mesos.TaskID)
- func (k *KubernetesExecutor) LaunchTask(driver mesos.ExecutorDriver, taskInfo *mesos.TaskInfo)
- func (k *KubernetesExecutor) Registered(driver mesos.ExecutorDriver, executorInfo *mesos.ExecutorInfo, ...)
- func (k *KubernetesExecutor) Reregistered(driver mesos.ExecutorDriver, slaveInfo *mesos.SlaveInfo)
- func (k *KubernetesExecutor) Shutdown(driver mesos.ExecutorDriver)
- type Server
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ListenAndServeKubeletServer ¶
func ListenAndServeKubeletServer(host HostInterface, address net.IP, port uint, enableDebuggingHandlers bool, sourcename string) error
ListenAndServeKubeletServer initializes a server to respond to HTTP network requests on the Kubelet.
Types ¶
type FlushWriter ¶ added in v0.2.2
type FlushWriter struct {
// contains filtered or unexported fields
}
FlushWriter provides wrapper for responseWriter with HTTP streaming capabilities
type HostInterface ¶
type HostInterface interface { GetContainerInfo(podFullName, uuid, containerName string, req *info.ContainerInfoRequest) (*info.ContainerInfo, error) GetRootInfo(req *info.ContainerInfoRequest) (*info.ContainerInfo, error) GetMachineInfo() (*info.MachineInfo, error) GetBoundPods() ([]api.BoundPod, error) GetPodInfo(name, uuid string) (api.PodInfo, error) GetKubeletContainerLogs(podFullName, containerName, tail string, follow bool, stdout, stderr io.Writer) error ServeLogs(w http.ResponseWriter, req *http.Request) }
HostInterface contains all the kubelet methods required by the server. For testablitiy.
type KubernetesExecutor ¶
type KubernetesExecutor struct {
// contains filtered or unexported fields
}
KubernetesExecutor is an mesos executor that runs pods in a minion machine.
func New ¶
func New(driver mesos.ExecutorDriver, kl *kubelet.Kubelet, ch chan<- interface{}, ns string) *KubernetesExecutor
New creates a new kubernetes executor.
func (*KubernetesExecutor) Disconnected ¶
func (k *KubernetesExecutor) Disconnected(driver mesos.ExecutorDriver)
Disconnected is called when the executor is disconnected with the slave.
func (*KubernetesExecutor) Error ¶
func (k *KubernetesExecutor) Error(driver mesos.ExecutorDriver, message string)
Error is called when some error happens.
func (*KubernetesExecutor) FrameworkMessage ¶
func (k *KubernetesExecutor) FrameworkMessage(driver mesos.ExecutorDriver, message string)
FrameworkMessage is called when the framework sends some message to the executor
func (*KubernetesExecutor) KillTask ¶
func (k *KubernetesExecutor) KillTask(driver mesos.ExecutorDriver, taskId *mesos.TaskID)
KillTask is called when the executor receives a request to kill a task.
func (*KubernetesExecutor) LaunchTask ¶
func (k *KubernetesExecutor) LaunchTask(driver mesos.ExecutorDriver, taskInfo *mesos.TaskInfo)
LaunchTask is called when the executor receives a request to launch a task.
func (*KubernetesExecutor) Registered ¶
func (k *KubernetesExecutor) Registered(driver mesos.ExecutorDriver, executorInfo *mesos.ExecutorInfo, frameworkInfo *mesos.FrameworkInfo, slaveInfo *mesos.SlaveInfo)
Registered is called when the executor is successfully registered with the slave.
func (*KubernetesExecutor) Reregistered ¶
func (k *KubernetesExecutor) Reregistered(driver mesos.ExecutorDriver, slaveInfo *mesos.SlaveInfo)
Reregistered is called when the executor is successfully re-registered with the slave. This can happen when the slave fails over.
func (*KubernetesExecutor) Shutdown ¶
func (k *KubernetesExecutor) Shutdown(driver mesos.ExecutorDriver)
Shutdown is called when the executor receives a shutdown request.
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server is a http.Handler which exposes kubelet functionality over HTTP.
func NewServer ¶
func NewServer(host HostInterface, enableDebuggingHandlers bool, ns string) Server
NewServer initializes and configures a kubelet.Server object to handle HTTP requests.
func (*Server) InstallDebuggingHandlers ¶ added in v0.2.2
func (s *Server) InstallDebuggingHandlers()
InstallDeguggingHandlers registers the HTTP request patterns that serve logs or run commands/containers
func (*Server) InstallDefaultHandlers ¶
func (s *Server) InstallDefaultHandlers()
InstallDefaultHandlers registers the set of supported HTTP request patterns with the mux.