statefulset

package
v1.1.16 Latest Latest
Warning

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

Go to latest
Published: Sep 3, 2021 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Build

func Build(opts ...Option) *appsv1.StatefulSet

Build runs each of the functions passed in to generate the object.

Types

type Builder

type Builder interface {
	Build(opts ...Option) *appsv1.StatefulSet

	Options(opts ...Option) Builder

	GenericOptions(opts ...generic.Option) Builder
}

func BasicBuilder

func BasicBuilder() Builder

func FullBuilder

func FullBuilder(namespace, name string, typer runtime.ObjectTyper) Builder

type Option

type Option func(*appsv1.StatefulSet)

Option defines a function signature for any function that wants to be passed into Build

func Generic

func Generic(opt generic.Option) Option

Generic allows common functions applicable to all objects to be used as Options to Build

func WithCurrentReplicas

func WithCurrentReplicas(currentReplicas int32) Option

WithCurrentReplicas sets the status.CurrentReplicas field when building an object with Build.

func WithName

func WithName(name string) Option

WithName sets the object.Name field when building an object with Build.

func WithNamespace

func WithNamespace(namespace string) Option

WithNamespace sets the object.Namespace field when building an object with Build.

func WithReplicas

func WithReplicas(replicas int32) Option

WithReplicas sets the spec.Replicas field when building an object with Build.

Jump to

Keyboard shortcuts

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