event

package
v0.25.1 Latest Latest
Warning

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

Go to latest
Published: Feb 24, 2022 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// EventTypeBuildInfo is a buildInfo event
	EventTypeBuildInfo EventType = "event.octant.dev/buildInfo"

	// EventTypeKubeConfigPath carries location of kube config with it
	EventTypeKubeConfigPath EventType = "event.octant.dev/kubeConfigPath"

	// EventTypeContent is a content event.
	EventTypeContent EventType = "event.octant.dev/content"

	// EventTypeNamespaces is a namespaces event.
	EventTypeNamespaces EventType = "event.octant.dev/namespaces"

	// EventTypeNavigation is a navigation event.
	EventTypeNavigation EventType = "event.octant.dev/navigation"

	// EventTypeObjectNotFound is an object not found event.
	EventTypeObjectNotFound EventType = "event.octant.dev/objectNotFound"

	// EventTypeCurrentNamespace is a current namespace event.
	EventTypeCurrentNamespace EventType = "event.octant.dev/currentNamespace"

	// EventTypeUnknown is an unknown event.
	EventTypeUnknown EventType = "event.octant.dev/unknown"

	// EventTypeNamespace is a namespace event.
	EventTypeNamespace EventType = "event.octant.dev/namespace"

	// EventTypeContext is a context event.
	EventTypeContext EventType = "event.octant.dev/context"

	// EventTypeKubeConfig is an event for updating kube contexts on the front end.
	EventTypeKubeConfig EventType = "event.octant.dev/kubeConfig"

	// EventTypeContentPath is a content path event.
	EventTypeContentPath EventType = "event.octant.dev/contentPath"

	// EventTypeFilters is a filters event.
	EventTypeFilters EventType = "event.octant.dev/filters"

	// EventTypeAlert is an alert event.
	EventTypeAlert EventType = "event.octant.dev/alert"

	// EventTypeRefresh is a refresh event.
	EventTypeRefresh EventType = "event.octant.dev/refresh"

	// EventTypeLoading is a loading event.
	EventTypeLoading EventType = "event.octant.dev/loading"

	// EventTypeAppLogs is an app logs event.
	EventTypeAppLogs EventType = "event.octant.dev/app-logs"

	// EventTypeTerminalFormat is a string with format specifiers to assist in generating
	// a terminal event type.
	EventTypeTerminalFormat string = "event.octant.dev/terminals/namespace/%s/pod/%s/container/%s"

	// EventTypeLoggingFormat is a string with format specifiers to assist in generating
	// a logging event type.
	EventTypeLoggingFormat string = "event.octant.dev/logging/namespace/%s/pod/%s"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Event

type Event struct {
	Type EventType   `json:"type"`
	Data interface{} `json:"data"`
	Err  error
}

Event is an event for the dash frontend.

func CreateEvent

func CreateEvent(eventType EventType, fields map[string]interface{}) Event

func FindEvent added in v0.21.0

func FindEvent(events []Event, evType EventType) (Event, error)

type EventType

type EventType string

func NewLoggingEventType

func NewLoggingEventType(namespace, pod string) EventType

NewLoggingEventType returns an event type for pod logs. This is the Event.Type that an Octant client will watch for to read the logging stream.

func NewTerminalEventType

func NewTerminalEventType(namespace, pod, container string) EventType

NewTerminalEventType returns an event type for a specific terminal instance. This is the Event.Type that an Octant client will watch for to read the terminal stream.

type WSClientGetter

type WSClientGetter interface {
	Get(id string) WSEventSender
}

type WSEventSender

type WSEventSender interface {
	Send(event Event)
}

Directories

Path Synopsis
Package fake is a generated GoMock package.
Package fake is a generated GoMock package.

Jump to

Keyboard shortcuts

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