v1alpha1

package
v0.0.0-...-cbc6286 Latest Latest
Warning

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

Go to latest
Published: Jul 6, 2019 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package v1alpha1 is the v1alpha1 version of the API. +groupName=argoproj.io +k8s:deepcopy-gen=package,register +k8s:openapi-gen=true

Index

Constants

View Source
const ArgoEventsGatewayVersion = "v0.10"

Gateway version

Variables

View Source
var (
	// SchemeBuilder is the builder for this scheme
	SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes)

	// AddToScheme adds this
	AddToScheme = SchemeBuilder.AddToScheme
)
View Source
var SchemaGroupVersionKind = schema.GroupVersionKind{Group: gateway.Group, Version: "v1alpha1", Kind: gateway.Kind}

SchemaGroupVersionKind is a group version kind used to attach owner references to gateway-controller

View Source
var SchemeGroupVersion = schema.GroupVersion{Group: gateway.Group, Version: "v1alpha1"}

SchemeGroupVersion is a group version used to register these objects

Functions

func Kind

func Kind(kind string) schema.GroupKind

Kind takes an unqualified kind and returns back a Group qualified GroupKind

func Resource

func Resource(resource string) schema.GroupResource

Resource takes unqualified resource and returns Group qualified GroupResource

Types

type Gateway

type Gateway struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata" protobuf:"bytes,1,opt,name=metadata"`
	Status            GatewayStatus `json:"status" protobuf:"bytes,2,opt,name=status"`
	Spec              GatewaySpec   `json:"spec" protobuf:"bytes,3,opt,name=spec"`
}

Gateway is the definition of a gateway resource +genclient +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +k8s:openapi-gen=true

func (*Gateway) DeepCopy

func (in *Gateway) DeepCopy() *Gateway

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Gateway.

func (*Gateway) DeepCopyInto

func (in *Gateway) DeepCopyInto(out *Gateway)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Gateway) DeepCopyObject

func (in *Gateway) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type GatewayList

type GatewayList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata" protobuf:"bytes,1,opt,name=metadata"`
	Items           []Gateway `json:"items" protobuf:"bytes,2,opt,name=items"`
}

GatewayList is the list of Gateway resources +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

func (*GatewayList) DeepCopy

func (in *GatewayList) DeepCopy() *GatewayList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GatewayList.

func (*GatewayList) DeepCopyInto

func (in *GatewayList) DeepCopyInto(out *GatewayList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*GatewayList) DeepCopyObject

func (in *GatewayList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type GatewayNotificationWatcher

type GatewayNotificationWatcher struct {
	// Name is the gateway name
	Name string `json:"name" protobuf:"bytes,1,opt,name=name"`

	// Port is http server port on which gateway is running
	Port string `json:"port" protobuf:"bytes,2,opt,name=port"`

	// Endpoint is REST API endpoint to post event to.
	// Events are sent using HTTP POST method to this endpoint.
	Endpoint string `json:"endpoint" protobuf:"bytes,3,opt,name=endpoint"`
}

GatewayNotificationWatcher is the gateway interested in listening to notifications from this gateway

func (*GatewayNotificationWatcher) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GatewayNotificationWatcher.

func (*GatewayNotificationWatcher) DeepCopyInto

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type GatewaySpec

type GatewaySpec struct {
	// Template is the pod specification for the gateway
	// Refer https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.11/#pod-v1-core
	Template *corev1.PodTemplateSpec `json:"template" protobuf:"bytes,1,opt,name=template"`

	// EventSource is name of the configmap that stores event source configurations for the gateway
	EventSource string `json:"eventSource,omitempty" protobuf:"bytes,2,opt,name=eventSource"`

	// Type is the type of gateway. Used as metadata.
	Type string `json:"type" protobuf:"bytes,3,opt,name=type"`

	// Service is the specifications of the service to expose the gateway
	// Refer https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.11/#service-v1-core
	Service *common.ServiceTemplateSpec `json:"service,omitempty" protobuf:"bytes,4,opt,name=service"`

	// Watchers are components which are interested listening to notifications from this gateway
	// These only need to be specified when gateway dispatch mechanism is through HTTP POST notifications.
	// In future, support for NATS, KAFKA will be added as a means to dispatch notifications in which case
	// specifying watchers would be unnecessary.
	Watchers *NotificationWatchers `json:"watchers,omitempty" protobuf:"bytes,5,opt,name=watchers"`

	// Port on which the gateway event source processor is running on.
	ProcessorPort string `json:"processorPort" protobuf:"bytes,6,opt,name=processorPort"`

	// EventProtocol is the underlying protocol used to send events from gateway to watchers(components interested in listening to event from this gateway)
	EventProtocol *common.EventProtocol `json:"eventProtocol" protobuf:"bytes,7,opt,name=eventProtocol"`
}

GatewaySpec represents gateway specifications

func (*GatewaySpec) DeepCopy

func (in *GatewaySpec) DeepCopy() *GatewaySpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GatewaySpec.

func (*GatewaySpec) DeepCopyInto

func (in *GatewaySpec) DeepCopyInto(out *GatewaySpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type GatewayStatus

type GatewayStatus struct {
	// Phase is the high-level summary of the gateway
	Phase NodePhase `json:"phase" protobuf:"bytes,1,opt,name=phase"`

	// StartedAt is the time at which this gateway was initiated
	StartedAt metav1.Time `json:"startedAt,omitempty" protobuf:"bytes,2,opt,name=startedAt"`

	// Message is a human readable string indicating details about a gateway in its phase
	Message string `json:"message,omitempty" protobuf:"bytes,4,opt,name=message"`

	// Nodes is a mapping between a node ID and the node's status
	// it records the states for the configurations of gateway.
	Nodes map[string]NodeStatus `json:"nodes,omitempty" protobuf:"bytes,5,rep,name=nodes"`
}

GatewayStatus contains information about the status of a gateway.

func (*GatewayStatus) DeepCopy

func (in *GatewayStatus) DeepCopy() *GatewayStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GatewayStatus.

func (*GatewayStatus) DeepCopyInto

func (in *GatewayStatus) DeepCopyInto(out *GatewayStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type NodePhase

type NodePhase string

NodePhase is the label for the condition of a node.

const (
	NodePhaseRunning        NodePhase = "Running"        // the node is running
	NodePhaseError          NodePhase = "Error"          // the node has encountered an error in processing
	NodePhaseNew            NodePhase = ""               // the node is new
	NodePhaseCompleted      NodePhase = "Completed"      // node has completed running
	NodePhaseRemove         NodePhase = "Remove"         // stale node
	NodePhaseResourceUpdate NodePhase = "ResourceUpdate" // resource is updated
)

possible types of node phases

type NodeStatus

type NodeStatus struct {
	// ID is a unique identifier of a node within a sensor
	// It is a hash of the node name
	ID string `json:"id" protobuf:"bytes,1,opt,name=id"`

	// Name is a unique name in the node tree used to generate the node ID
	Name string `json:"name" protobuf:"bytes,3,opt,name=name"`

	// DisplayName is the human readable representation of the node
	DisplayName string `json:"displayName" protobuf:"bytes,5,opt,name=displayName"`

	// Phase of the node
	Phase NodePhase `json:"phase" protobuf:"bytes,6,opt,name=phase"`

	// StartedAt is the time at which this node started
	// +k8s:openapi-gen=false
	StartedAt metav1.MicroTime `json:"startedAt,omitempty" protobuf:"bytes,7,opt,name=startedAt"`

	// Message store data or something to save for configuration
	Message string `json:"message,omitempty" protobuf:"bytes,8,opt,name=message"`

	// UpdateTime is the time when node(gateway configuration) was updated
	UpdateTime metav1.MicroTime `json:"updateTime,omitempty" protobuf:"bytes,9,opt,name=updateTime"`
}

NodeStatus describes the status for an individual node in the gateway configurations. A single node can represent one configuration.

func (*NodeStatus) DeepCopy

func (in *NodeStatus) DeepCopy() *NodeStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeStatus.

func (*NodeStatus) DeepCopyInto

func (in *NodeStatus) DeepCopyInto(out *NodeStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type NotificationWatchers

type NotificationWatchers struct {
	// Gateways is the list of gateways interested in listening to notifications from this gateway
	Gateways []GatewayNotificationWatcher `json:"gateways,omitempty" protobuf:"bytes,1,opt,name=gateways"`

	// Sensors is the list of sensors interested in listening to notifications from this gateway
	Sensors []SensorNotificationWatcher `json:"sensors,omitempty" protobuf:"bytes,2,rep,name=sensors"`
}

NotificationWatchers are components which are interested listening to notifications from this gateway

func (*NotificationWatchers) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NotificationWatchers.

func (*NotificationWatchers) DeepCopyInto

func (in *NotificationWatchers) DeepCopyInto(out *NotificationWatchers)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type SensorNotificationWatcher

type SensorNotificationWatcher struct {
	// Name is name of the sensor
	Name string `json:"name" protobuf:"bytes,1,opt,name=name"`
}

SensorNotificationWatcher is the sensor interested in listening to notifications from this gateway

func (*SensorNotificationWatcher) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new SensorNotificationWatcher.

func (*SensorNotificationWatcher) DeepCopyInto

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

Jump to

Keyboard shortcuts

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