v1alpha1

package
v0.2.0-release Latest Latest
Warning

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

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

Documentation

Overview

Package v1alpha1 contains API Schema definitions for the nifi v1alpha1 API group +k8s:deepcopy-gen=package,register +groupName=nifi.orange.com

Package v1alpha1 contains API Schema definitions for the nifi v1alpha1 API group +k8s:deepcopy-gen=package,register +groupName=nifi.orange.com

Index

Constants

View Source
const (
	// UserStateCreated describes the status of a NifiUser as created
	UserStateCreated UserState = "created"
	// TLSCert is where a cert is stored in a user secret when requested
	TLSCert string = "tls.crt"
	// TLSCert is where a private key is stored in a user secret when requested
	TLSKey string = "tls.key"
	// TLSJKSKey is where a JKS is stored in a user secret when requested
	TLSJKSKey string = "tls.jks"
	// CoreCACertKey is where ca ceritificates are stored in user certificates
	CoreCACertKey string = "ca.crt"
	// CACertKey is the key where the CA certificate is stored in the operator secrets
	CACertKey string = "caCert"
	// CAPrivateKeyKey stores the private key for the CA
	CAPrivateKeyKey string = "caKey"
	// ClientCertKey stores the client certificate (operator usage)
	ClientCertKey string = "clientCert"
	// ClientPrivateKeyKey stores the client private key
	ClientPrivateKeyKey string = "clientKey"
	// PeerCertKey stores the peer certificate (node certificates)
	PeerCertKey string = "peerCert"
	// PeerPrivateKeyKey stores the peer private key
	PeerPrivateKeyKey string = "peerKey"
	// PasswordKey stores the JKS password
	PasswordKey string = "password"
)
View Source
const (
	// Configured states the node is running
	Configured RackAwarenessState = "Configured"

	// GracefulUpscaleRequired states that a node upscale is required
	GracefulUpscaleRequired State = "GracefulUpscaleRequired"
	// GracefulUpscaleRunning states that the node upscale task is still running
	GracefulUpscaleRunning State = "GracefulUpscaleRunning"
	// GracefulUpscaleSucceeded states the node is updated gracefully
	GracefulUpscaleSucceeded State = "GracefulUpscaleSucceeded"

	// Downscale nifi cluster states
	// GracefulDownscaleRequired states that a node downscale is required
	GracefulDownscaleRequired State = "GracefulDownscaleRequired"
	// GracefulDownscaleRunning states that the node downscale is still running in
	GracefulDownscaleRunning State = "GracefulDownscaleRunning"
	// GracefulUpscaleSucceeded states the node is updated gracefully
	GracefulDownscaleSucceeded State = "GracefulDownscaleSucceeded"

	// NifiClusterInitializing states that the cluster is still in initializing stage
	NifiClusterInitializing ClusterState = "ClusterInitializing"
	// NifiClusterInitialized states that the cluster is initialized
	NifiClusterInitialized ClusterState = "ClusterInitialized"
	// NifiClusterReconciling states that the cluster is still in reconciling stage
	NifiClusterReconciling ClusterState = "ClusterReconciling"
	// NifiClusterRollingUpgrading states that the cluster is rolling upgrading
	NifiClusterRollingUpgrading ClusterState = "ClusterRollingUpgrading"
	// NifiClusterRunning states that the cluster is in running state
	NifiClusterRunning ClusterState = "ClusterRunning"

	// ConfigInSync states that the generated nodeConfig is in sync with the Node
	ConfigInSync ConfigurationState = "ConfigInSync"
	// ConfigOutOfSync states that the generated nodeConfig is out of sync with the Node
	ConfigOutOfSync ConfigurationState = "ConfigOutOfSync"

	// DisconnectNodeAction states that the NiFi node is disconnecting from NiFi Cluster
	DisconnectNodeAction ActionStep = "DISCONNECTING"
	// DisconnectStatus states that the NiFi node is disconnected from NiFi Cluster
	DisconnectStatus ActionStep = "DISCONNECTED"
	// OffloadNodeAction states that the NiFi node is offloading data to NiFi Cluster
	OffloadNodeAction ActionStep = "OFFLOADING"
	// OffloadStatus states that the NiFi node offloaded data to NiFi Cluster
	OffloadStatus ActionStep = "OFFLOADED"
	// RemovePodAction states that the NiFi node pod and object related are removing by operator.
	RemovePodAction ActionStep = "POD_REMOVING"
	// RemovePodAction states that the NiFi node pod and object related have been removed by operator.
	RemovePodStatus ActionStep = "POD_REMOVED"
	// RemoveNodeAction states that the NiFi node is removing from NiFi Cluster
	RemoveNodeAction ActionStep = "REMOVING"
	// RemoveStatus states that the NiFi node is removed from NiFi Cluster
	RemoveStatus ActionStep = "REMOVED"
	// ConnectNodeAction states that the NiFi node is connecting to the NiFi Cluster
	ConnectNodeAction ActionStep = "CONNECTING"
	// ConnectStatus states that the NiFi node is connected to the NiFi Cluster
	ConnectStatus ActionStep = "CONNECTED"

	// IsInitClusterNode states the node is part of initial cluster setup
	IsInitClusterNode InitClusterNode = true
	// NotInitClusterNode states the node is not part of initial cluster setup
	NotInitClusterNode InitClusterNode = false
)
View Source
const (
	ClusterListenerType = "cluster"
	HttpListenerType    = "http"
	HttpsListenerType   = "https"
	S2sListenerType     = "s2s"
	MetricsPort         = 9020
)

Variables

View Source
var (
	// SchemeGroupVersion is group version used to register these objects
	SchemeGroupVersion = schema.GroupVersion{Group: "nifi.orange.com", Version: "v1alpha1"}

	// SchemeBuilder is used to add go types to the GroupVersionKind scheme
	SchemeBuilder = &scheme.Builder{GroupVersion: SchemeGroupVersion}
)

Functions

Types

type ActionStep

type ActionStep string

Action step holds info about the action step

type BootstrapProperties

type BootstrapProperties struct {
	// JVM memory settings
	NifiJvmMemory string `json:"nifiJvmMemory,omitempty"`
	// Additionnals bootstrap.properties configuration that will override the one produced based
	// on template and configurations.
	OverrideConfigs string `json:"overrideConfigs,omitempty"`
}

BootstrapProperties configuration that will be applied to the node.

func (*BootstrapProperties) DeepCopy

func (in *BootstrapProperties) DeepCopy() *BootstrapProperties

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

func (*BootstrapProperties) DeepCopyInto

func (in *BootstrapProperties) DeepCopyInto(out *BootstrapProperties)

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

func (*BootstrapProperties) GetNifiJvmMemory

func (bProperties *BootstrapProperties) GetNifiJvmMemory() string

GetNifiJvmMemory returns the default "2g" NifiJvmMemory if not specified otherwise

type ClusterReference

type ClusterReference struct {
	Name      string `json:"name"`
	Namespace string `json:"namespace,omitempty"`
}

ClusterReference states a reference to a cluster for topic/user provisioning

func (*ClusterReference) DeepCopy

func (in *ClusterReference) DeepCopy() *ClusterReference

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

func (*ClusterReference) DeepCopyInto

func (in *ClusterReference) DeepCopyInto(out *ClusterReference)

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

type ClusterState

type ClusterState string

ClusterState holds info about the cluster state

type ConfigurationState

type ConfigurationState string

ConfigurationState holds info about the configuration state

type ExternalListenerConfig

type ExternalListenerConfig struct {
	// TODO: remove type field # specific to Nifi ?
	//
	Type string `json:"type"`
	//
	Name string `json:"name"`
	//
	ExternalStartingPort int32 `json:"externalStartingPort"`
	//
	ContainerPort int32 `json:"containerPort"`
	//
	HostnameOverride string `json:"hostnameOverride,omitempty"`
}

ExternalListenerConfig defines the external listener config for Nifi TODO: enable configuration of ingress or something like this.

func (*ExternalListenerConfig) DeepCopy

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

func (*ExternalListenerConfig) DeepCopyInto

func (in *ExternalListenerConfig) DeepCopyInto(out *ExternalListenerConfig)

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

type GracefulActionState

type GracefulActionState struct {
	// ErrorMessage holds the information what happened with Nifi Cluster
	ErrorMessage string `json:"errorMessage"`
	// ActionStep holds info about the action step ran
	ActionStep ActionStep `json:"actionStep,omitempty"`
	// TaskStarted hold the time when the execution started
	TaskStarted string `json:"TaskStarted,omitempty"`
	// ActionState holds the information about Action state
	State State `json:"actionState"`
}

GracefulActionState holds information about GracefulAction State

func (*GracefulActionState) DeepCopy

func (in *GracefulActionState) DeepCopy() *GracefulActionState

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

func (*GracefulActionState) DeepCopyInto

func (in *GracefulActionState) DeepCopyInto(out *GracefulActionState)

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

type InitClusterNode

type InitClusterNode bool

InitClusterNode holds info about if the node was part of the init cluster setup

type InternalListenerConfig

type InternalListenerConfig struct {
	// +kubebuilder:validation:Enum={"cluster", "http", "https", "s2s"}
	// (Optional field) Type allow to specify if we are in a specific nifi listener
	// it's allowing to define some required information such as Cluster Port,
	// Http Port, Https Port or S2S port
	Type string `json:"type,omitempty"`
	// An identifier for the port which will be configured.
	Name string `json:"name"`
	// The container port.
	ContainerPort int32 `json:"containerPort"`
}

InternalListenerConfig defines the internal listener config for Nifi

func (*InternalListenerConfig) DeepCopy

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

func (*InternalListenerConfig) DeepCopyInto

func (in *InternalListenerConfig) DeepCopyInto(out *InternalListenerConfig)

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

type LdapConfiguration

type LdapConfiguration struct {
	// If set to true, we will enable ldap usage into nifi.properties configuration.
	Enabled bool `json:"enabled,omitempty"`
	// Space-separated list of URLs of the LDAP servers (i.e. ldap://<hostname>:<port>).
	Url string `json:"url,omitempty"`
	// Base DN for searching for users (i.e. CN=Users,DC=example,DC=com).
	SearchBase string `json:"searchBase,omitempty"`
	// Filter for searching for users against the 'User Search Base'.
	// (i.e. sAMAccountName={0}). The user specified name is inserted into '{0}'.
	SearchFilter string `json:"searchFilter,omitempty"`
}

LdapConfiguration specifies the configuration if you want to use LDAP

func (*LdapConfiguration) DeepCopy

func (in *LdapConfiguration) DeepCopy() *LdapConfiguration

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

func (*LdapConfiguration) DeepCopyInto

func (in *LdapConfiguration) DeepCopyInto(out *LdapConfiguration)

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

type ListenersConfig

type ListenersConfig struct {
	// externalListeners specifies settings required to access nifi externally
	// TODO: enable externalListener configuration
	//ExternalListeners []ExternalListenerConfig `json:"externalListeners,omitempty"`
	// internalListeners specifies settings required to access nifi internally
	InternalListeners []InternalListenerConfig `json:"internalListeners"`
	// sslSecrets contains information about ssl related kubernetes secrets if one of the
	// listener setting type set to ssl these fields must be populated to
	SSLSecrets *SSLSecrets `json:"sslSecrets,omitempty"`
	// clusterDomain allow to override the default cluster domain which is "cluster.local"
	ClusterDomain string `json:"clusterDomain,omitempty"`
	// useExternalDNS allow to manage externalDNS usage by limiting the DNS names associated
	// to each nodes and load balancer : <cluster-name>-node-<node Id>.<cluster-name>.<service name>.<cluster domain>
	UseExternalDNS bool `json:"useExternalDNS,omitempty"`
}

ListenersConfig defines the Nifi listener types

func (*ListenersConfig) DeepCopy

func (in *ListenersConfig) DeepCopy() *ListenersConfig

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

func (*ListenersConfig) DeepCopyInto

func (in *ListenersConfig) DeepCopyInto(out *ListenersConfig)

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

func (*ListenersConfig) GetClusterDomain

func (lConfig *ListenersConfig) GetClusterDomain() string

type NifiAccessType

type NifiAccessType string

NifiAccessType hold info about Nifi ACL

type NifiCluster

type NifiCluster struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   NifiClusterSpec   `json:"spec,omitempty"`
	Status NifiClusterStatus `json:"status,omitempty"`
}

NifiCluster is the Schema for the nificlusters API +kubebuilder:subresource:status +kubebuilder:resource:path=nificlusters,scope=Namespaced

func (*NifiCluster) DeepCopy

func (in *NifiCluster) DeepCopy() *NifiCluster

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

func (*NifiCluster) DeepCopyInto

func (in *NifiCluster) DeepCopyInto(out *NifiCluster)

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

func (*NifiCluster) DeepCopyObject

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

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

type NifiClusterList

type NifiClusterList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []NifiCluster `json:"items"`
}

NifiClusterList contains a list of NifiCluster

func (*NifiClusterList) DeepCopy

func (in *NifiClusterList) DeepCopy() *NifiClusterList

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

func (*NifiClusterList) DeepCopyInto

func (in *NifiClusterList) DeepCopyInto(out *NifiClusterList)

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

func (*NifiClusterList) DeepCopyObject

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

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

type NifiClusterSpec

type NifiClusterSpec struct {
	// Service defines the policy for services owned by NiFiKop operator.
	Service ServicePolicy `json:"service,omitempty"`
	// Pod defines the policy for  pods owned by NiFiKop operator.
	Pod PodPolicy `json:"pod,omitempty"`
	// zKAddresse specifies the ZooKeeper connection string
	// in the form hostname:port where host and port are those of a Zookeeper server.
	// TODO: rework for nice zookeeper connect string =
	ZKAddresse string `json:"zkAddresse"`
	// zKPath specifies the Zookeeper chroot path as part
	// of its Zookeeper connection string which puts its data under same path in the global ZooKeeper namespace.
	ZKPath string `json:"zkPath,omitempty"`
	// initContainerImage can override the default image used into the init container to check if
	// ZoooKeeper server is reachable.
	InitContainerImage string `json:"initContainerImage,omitempty"`
	// initContainers defines additional initContainers configurations
	InitContainers []corev1.Container `json:"initContainers,omitempty" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,2,rep,name=containers"`
	// clusterImage can specify the whole NiFi cluster image in one place
	ClusterImage string `json:"clusterImage,omitempty"`
	// Cluster nodes secure mode : https://nifi.apache.org/docs/nifi-docs/html/administration-guide.html#cluster_common_properties
	// TODO : rework to define into internalListener ! (Note: if ssl enabled need Cluster & SiteToSite & Https port)
	ClusterSecure bool `json:"clusterSecure,omitempty"`
	// Site to Site properties Secure mode : https://nifi.apache.org/docs/nifi-docs/html/administration-guide.html#site_to_site_properties
	// TODO : rework to define into internalListener !
	SiteToSiteSecure bool `json:"siteToSiteSecure,omitempty"`
	// oneNifiNodePerNode if set to true every nifi node is started on a new node, if there is not enough node to do that
	// it will stay in pending state. If set to false the operator also tries to schedule the nifi node to a unique node
	// but if the node number is insufficient the nifi node will be scheduled to a node where a nifi node is already running.
	OneNifiNodePerNode bool `json:"oneNifiNodePerNode"`
	// propage
	PropagateLabels bool `json:"propagateLabels,omitempty"`
	// TODO : remove once the user management is implemented into the operator
	InitialAdminUser string `json:"initialAdminUser,omitempty""`
	// readOnlyConfig specifies the read-only type Nifi config cluster wide, all theses
	// will be merged with node specified readOnly configurations, so it can be overwritten per node.
	ReadOnlyConfig ReadOnlyConfig `json:"readOnlyConfig,omitempty"`
	// nodeConfigGroups specifies multiple node configs with unique name
	NodeConfigGroups map[string]NodeConfig `json:"nodeConfigGroups,omitempty"`
	// all node requires an image, unique id, and storageConfigs settings
	Nodes []Node `json:"nodes"`
	// LdapConfiguration specifies the configuration if you want to use LDAP
	LdapConfiguration LdapConfiguration `json:"ldapConfiguration,omitempty"`
	// NifiClusterTaskSpec specifies the configuration of the nifi cluster Tasks
	NifiClusterTaskSpec NifiClusterTaskSpec `json:"nifiClusterTaskSpec,omitempty"`
	// TODO : add vault
	//VaultConfig         	VaultConfig         `json:"vaultConfig,omitempty"`
	// listenerConfig specifies nifi's listener specifig configs
	ListenersConfig ListenersConfig `json:"listenersConfig"`
}

NifiClusterSpec defines the desired state of NifiCluster

func (*NifiClusterSpec) DeepCopy

func (in *NifiClusterSpec) DeepCopy() *NifiClusterSpec

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

func (*NifiClusterSpec) DeepCopyInto

func (in *NifiClusterSpec) DeepCopyInto(out *NifiClusterSpec)

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

func (*NifiClusterSpec) GetInitContainerImage

func (nSpec *NifiClusterSpec) GetInitContainerImage() string

func (*NifiClusterSpec) GetZkPath

func (nSpec *NifiClusterSpec) GetZkPath() string

GetZkPath returns the default "/" ZkPath if not specified otherwise

type NifiClusterStatus

type NifiClusterStatus struct {
	// Store the state of each nifi node
	NodesState map[string]NodeState `json:"nodesState,omitempty"`
	// ClusterState holds info about the cluster state
	State ClusterState `json:"state"`
	// RollingUpgradeStatus defines status of rolling upgrade
	RollingUpgrade RollingUpgradeStatus `json:"rollingUpgradeStatus,omitempty"`
}

NifiClusterStatus defines the observed state of NifiCluster

func (*NifiClusterStatus) DeepCopy

func (in *NifiClusterStatus) DeepCopy() *NifiClusterStatus

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

func (*NifiClusterStatus) DeepCopyInto

func (in *NifiClusterStatus) DeepCopyInto(out *NifiClusterStatus)

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

type NifiClusterTaskSpec

type NifiClusterTaskSpec struct {
	// RetryDurationMinutes describes the amount of time the Operator waits for the task
	RetryDurationMinutes int `json:"retryDurationMinutes"`
}

NifiClusterTaskSpec specifies the configuration of the nifi cluster Tasks

func (*NifiClusterTaskSpec) DeepCopy

func (in *NifiClusterTaskSpec) DeepCopy() *NifiClusterTaskSpec

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

func (*NifiClusterTaskSpec) DeepCopyInto

func (in *NifiClusterTaskSpec) DeepCopyInto(out *NifiClusterTaskSpec)

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

func (*NifiClusterTaskSpec) GetDurationMinutes

func (nTaskSpec *NifiClusterTaskSpec) GetDurationMinutes() float64

type NifiProperties

type NifiProperties struct {
	// Additionnals nifi.properties configuration that will override the one produced based
	// on template and configurations.
	OverrideConfigs string `json:"overrideConfigs,omitempty"`
	// A comma separated list of allowed HTTP Host header values to consider when NiFi
	// is running securely and will be receiving requests to a different host[:port] than it is bound to.
	// https://nifi.apache.org/docs/nifi-docs/html/administration-guide.html#web-properties
	WebProxyHosts []string `json:"webProxyHosts,omitempty"`
	// Nifi security client auth
	NeedClientAuth bool `json:"needClientAuth,omitempty"`
	// Indicates which of the configured authorizers in the authorizers.xml file to use
	// https://nifi.apache.org/docs/nifi-docs/html/administration-guide.html#authorizer-configuration
	Authorizer string `json:"authorizer,omitempty"`
}

NifiProperties configuration that will be applied to the node.

func (*NifiProperties) DeepCopy

func (in *NifiProperties) DeepCopy() *NifiProperties

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

func (*NifiProperties) DeepCopyInto

func (in *NifiProperties) DeepCopyInto(out *NifiProperties)

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

func (NifiProperties) GetAuthorizer

func (nProperties NifiProperties) GetAuthorizer() string

type NifiUser

type NifiUser struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   NifiUserSpec   `json:"spec,omitempty"`
	Status NifiUserStatus `json:"status,omitempty"`
}

Nifi User is the Schema for the nifi users API +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object +k8s:openapi-gen=true +kubebuilder:object:root=true +kubebuilder:subresource:status

func (*NifiUser) DeepCopy

func (in *NifiUser) DeepCopy() *NifiUser

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

func (*NifiUser) DeepCopyInto

func (in *NifiUser) DeepCopyInto(out *NifiUser)

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

func (*NifiUser) DeepCopyObject

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

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

type NifiUserList

type NifiUserList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []NifiUser `json:"items"`
}

NifiUserList contains a list of NifiUser

func (*NifiUserList) DeepCopy

func (in *NifiUserList) DeepCopy() *NifiUserList

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

func (*NifiUserList) DeepCopyInto

func (in *NifiUserList) DeepCopyInto(out *NifiUserList)

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

func (*NifiUserList) DeepCopyObject

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

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

type NifiUserSpec

type NifiUserSpec struct {
	// Name of the secret where all cert resources will be stored
	SecretName string `json:"secretName"`
	// contains the reference to the NifiCluster with the one the user is linked
	ClusterRef ClusterReference `json:"clusterRef"`
	// List of DNSNames that the user will used to request the NifiCluster (allowing to create the right certificates associated)
	DNSNames []string `json:"dnsNames,omitempty"`

	// Whether or not the the operator also include a Java keystore format (JKS) with you secret
	IncludeJKS bool `json:"includeJKS,omitempty"`
}

NifiUserSpec defines the desired state of NifiUser +k8s:openapi-gen=true

func (*NifiUserSpec) DeepCopy

func (in *NifiUserSpec) DeepCopy() *NifiUserSpec

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

func (*NifiUserSpec) DeepCopyInto

func (in *NifiUserSpec) DeepCopyInto(out *NifiUserSpec)

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

type NifiUserStatus

type NifiUserStatus struct {
	State UserState `json:"state"`
}

NifiUserStatus defines the observed state of NifiUser +k8s:openapi-gen=true

func (*NifiUserStatus) DeepCopy

func (in *NifiUserStatus) DeepCopy() *NifiUserStatus

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

func (*NifiUserStatus) DeepCopyInto

func (in *NifiUserStatus) DeepCopyInto(out *NifiUserStatus)

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

type Node

type Node struct {
	// Unique Node id
	Id int32 `json:"id"`
	// nodeConfigGroup can be used to ease the node configuration, if set no only the id is required
	NodeConfigGroup string `json:"nodeConfigGroup,omitempty"`
	// readOnlyConfig can be used to pass Nifi node config https://nifi.apache.org/docs/nifi-docs/html/administration-guide.html
	// which has type read-only these config changes will trigger rolling upgrade
	ReadOnlyConfig *ReadOnlyConfig `json:"readOnlyConfig,omitempty"`
	// node configuration
	NodeConfig *NodeConfig `json:"nodeConfig,omitempty"`
}

Node defines the nifi node basic configuration

func (*Node) DeepCopy

func (in *Node) DeepCopy() *Node

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

func (*Node) DeepCopyInto

func (in *Node) DeepCopyInto(out *Node)

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

type NodeConfig

type NodeConfig struct {
	// provenanceStorage allow to specify the maximum amount of data provenance information to store at a time
	// https://nifi.apache.org/docs/nifi-docs/html/administration-guide.html#write-ahead-provenance-repository-properties
	ProvenanceStorage string `json:"provenanceStorage,omitempty"`
	//RunAsUser define the id of the user to run in the Nifi image
	// +kubebuilder:validation:Minimum=1
	RunAsUser *int64 `json:"runAsUser,omitempty"`
	// Set this to true if the instance is a node in a cluster.
	// https://nifi.apache.org/docs/nifi-docs/html/administration-guide.html#basic-cluster-setup
	IsNode *bool `json:"isNode,omitempty"`
	//  Docker image used by the operator to create the node associated
	//  https://hub.docker.com/r/apache/nifi/
	Image string `json:"image,omitempty"`
	// imagePullPolicy define the pull policy for NiFi cluster docker image
	ImagePullPolicy corev1.PullPolicy `json:"imagePullPolicy,omitempty"`
	// nodeAffinity can be specified, operator populates this value if new pvc added later to node
	NodeAffinity *corev1.NodeAffinity `json:"nodeAffinity,omitempty"`
	// storageConfigs specifies the node related configs
	StorageConfigs []StorageConfig `json:"storageConfigs,omitempty"`
	// serviceAccountName specifies the serviceAccount used for this specific node
	ServiceAccountName string `json:"serviceAccountName,omitempty"`
	// resourceRequirements works exactly like Container resources, the user can specify the limit and the requests
	// through this property
	// https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/
	ResourcesRequirements *corev1.ResourceRequirements `json:"resourcesRequirements,omitempty"`
	// imagePullSecrets specifies the secret to use when using private registry
	// https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.11/#localobjectreference-v1-core
	ImagePullSecrets []corev1.LocalObjectReference `json:"imagePullSecrets,omitempty"`
	// nodeSelector can be specified, which set the pod to fit on a node
	// https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#nodeselector
	NodeSelector map[string]string `json:"nodeSelector,omitempty"`
	// tolerations can be specified, which set the pod's tolerations
	// https://kubernetes.io/docs/concepts/configuration/taint-and-toleration/#concepts
	Tolerations []corev1.Toleration `json:"tolerations,omitempty"`
	// Additionnal annotation to attach to the pod associated
	// https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/#syntax-and-character-set
	NodeAnnotations map[string]string `json:"nifiAnnotations,omitempty"`
}

NodeConfig defines the node configuration

func (*NodeConfig) DeepCopy

func (in *NodeConfig) DeepCopy() *NodeConfig

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

func (*NodeConfig) DeepCopyInto

func (in *NodeConfig) DeepCopyInto(out *NodeConfig)

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

func (*NodeConfig) GetImagePullPolicy

func (nConfig *NodeConfig) GetImagePullPolicy() corev1.PullPolicy

GetImagePullPolicy returns the image pull policy to pull containers images

func (*NodeConfig) GetImagePullSecrets

func (nConfig *NodeConfig) GetImagePullSecrets() []corev1.LocalObjectReference

GetImagePullSecrets returns the list of Secrets needed to pull Containers images from private repositories

func (*NodeConfig) GetIsNode

func (nConfig *NodeConfig) GetIsNode() bool

func (*NodeConfig) GetNodeAnnotations

func (nConfig *NodeConfig) GetNodeAnnotations() map[string]string

func (*NodeConfig) GetNodeSelector

func (nConfig *NodeConfig) GetNodeSelector() map[string]string

GetNodeSelector returns the node selector for the given node

func (*NodeConfig) GetProvenanceStorage

func (nConfig *NodeConfig) GetProvenanceStorage() string

func (*NodeConfig) GetResources

func (nConfig *NodeConfig) GetResources() *corev1.ResourceRequirements

GetResources returns the nifi node specific Kubernetes resource

func (*NodeConfig) GetRunAsUser

func (nConfig *NodeConfig) GetRunAsUser() *int64

func (*NodeConfig) GetServiceAccount

func (nConfig *NodeConfig) GetServiceAccount() string

GetServiceAccount returns the Kubernetes Service Account to use for Nifi Cluster

func (*NodeConfig) GetTolerations

func (nConfig *NodeConfig) GetTolerations() []corev1.Toleration

GetTolerations returns the tolerations for the given node

type NodeState

type NodeState struct {
	// GracefulActionState holds info about nifi cluster action status
	GracefulActionState GracefulActionState `json:"gracefulActionState"`
	// ConfigurationState holds info about the config
	ConfigurationState ConfigurationState `json:"configurationState"`
	// InitClusterNode contains if this nodes was part of the initial cluster
	InitClusterNode InitClusterNode `json:"initClusterNode"`
}

NifiState holds information about nifi state

func (*NodeState) DeepCopy

func (in *NodeState) DeepCopy() *NodeState

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

func (*NodeState) DeepCopyInto

func (in *NodeState) DeepCopyInto(out *NodeState)

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

type PKIBackend

type PKIBackend string

PKIBackend represents an interface implementing the PKIManager

const (
	// PKIBackendCertManager invokes cert-manager for user certificate management
	PKIBackendCertManager PKIBackend = "cert-manager"
)

type PodPolicy

type PodPolicy struct {
	// Annotations specifies the annotations to attach to pods the operator creates
	Annotations map[string]string `json:"annotations,omitempty"`
}

func (*PodPolicy) DeepCopy

func (in *PodPolicy) DeepCopy() *PodPolicy

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

func (*PodPolicy) DeepCopyInto

func (in *PodPolicy) DeepCopyInto(out *PodPolicy)

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

type RackAwarenessState

type RackAwarenessState string

RackAwarenessState stores info about rack awareness status

type ReadOnlyConfig

type ReadOnlyConfig struct {
	// NifiProperties configuration that will be applied to the node.
	NifiProperties NifiProperties `json:"nifiProperties,omitempty"`
	// ZookeeperProperties configuration that will be applied to the node.
	ZookeeperProperties ZookeeperProperties `json:"zookeeperProperties,omitempty"`
	// BootstrapProperties configuration that will be applied to the node.
	BootstrapProperties BootstrapProperties `json:"bootstrapProperties,omitempty"`
}

func (*ReadOnlyConfig) DeepCopy

func (in *ReadOnlyConfig) DeepCopy() *ReadOnlyConfig

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

func (*ReadOnlyConfig) DeepCopyInto

func (in *ReadOnlyConfig) DeepCopyInto(out *ReadOnlyConfig)

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

type RollingUpgradeStatus

type RollingUpgradeStatus struct {
	//
	LastSuccess string `json:"lastSuccess"`
	//
	ErrorCount int `json:"errorCount"`
}

RollingUpgradeStatus defines status of rolling upgrade

func (*RollingUpgradeStatus) DeepCopy

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

func (*RollingUpgradeStatus) DeepCopyInto

func (in *RollingUpgradeStatus) DeepCopyInto(out *RollingUpgradeStatus)

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

type SSLSecrets

type SSLSecrets struct {
	// tlsSecretName should contain all ssl certs required by nifi including: caCert, caKey, clientCert, clientKey
	// serverCert, serverKey, peerCert, peerKey
	TLSSecretName string `json:"tlsSecretName"`
	// create tells the installed cert manager to create the required certs keys
	Create bool `json:"create,omitempty"`
	// clusterScoped defines if the Issuer created is cluster or namespace scoped
	ClusterScoped bool `json:"clusterScoped,omitempty"`
	// issuerRef allow to use an existing issuer to act as CA :
	// https://cert-manager.io/docs/concepts/issuer/
	IssuerRef *cmmeta.ObjectReference `json:"issuerRef,omitempty"`
	// TODO : add vault
	// +kubebuilder:validation:Enum={"cert-manager","vault"}
	PKIBackend PKIBackend `json:"pkiBackend,omitempty"`
}

SSLSecrets defines the Nifi SSL secrets

func (*SSLSecrets) DeepCopy

func (in *SSLSecrets) DeepCopy() *SSLSecrets

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

func (*SSLSecrets) DeepCopyInto

func (in *SSLSecrets) DeepCopyInto(out *SSLSecrets)

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

type ServicePolicy

type ServicePolicy struct {
	// HeadlessEnabled specifies if the cluster should use headlessService for Nifi or individual services
	// using service per nodes may come an handy case of service mesh.
	HeadlessEnabled bool `json:"headlessEnabled"`
	// Annotations specifies the annotations to attach to services the operator creates
	Annotations map[string]string `json:"annotations,omitempty"`
}

func (*ServicePolicy) DeepCopy

func (in *ServicePolicy) DeepCopy() *ServicePolicy

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

func (*ServicePolicy) DeepCopyInto

func (in *ServicePolicy) DeepCopyInto(out *ServicePolicy)

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

type State

type State string

State holds info about the state of action

func (State) Complete

func (r State) Complete() State

func (State) IsDownscale

func (r State) IsDownscale() bool

func (State) IsRequiredState

func (r State) IsRequiredState() bool

func (State) IsRunningState

func (r State) IsRunningState() bool

func (State) IsUpscale

func (r State) IsUpscale() bool

type StorageConfig

type StorageConfig struct {
	// Name of the storage config, used to name PV to reuse into sidecars for example.
	// +kubebuilder:validation:Pattern=[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*
	Name string `json:"name"`
	// Path where the volume will be mount into the main nifi container inside the pod.
	MountPath string `json:"mountPath"`
	// Kubernetes PVC spec
	PVCSpec *corev1.PersistentVolumeClaimSpec `json:"pvcSpec"`
}

StorageConfig defines the node storage configuration

func (*StorageConfig) DeepCopy

func (in *StorageConfig) DeepCopy() *StorageConfig

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

func (*StorageConfig) DeepCopyInto

func (in *StorageConfig) DeepCopyInto(out *StorageConfig)

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

type UserState

type UserState string

UserState defines the state of a NifiUser

type ZookeeperProperties

type ZookeeperProperties struct {
	// Additionnals zookeeper.properties configuration that will override the one produced based
	// on template and configurations.
	OverrideConfigs string `json:"overrideConfigs,omitempty"`
}

ZookeeperProperties configuration that will be applied to the node.

func (*ZookeeperProperties) DeepCopy

func (in *ZookeeperProperties) DeepCopy() *ZookeeperProperties

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

func (*ZookeeperProperties) DeepCopyInto

func (in *ZookeeperProperties) DeepCopyInto(out *ZookeeperProperties)

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