kubernetes

package
v0.0.0-...-f266d1f Latest Latest
Warning

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

Go to latest
Published: Feb 5, 2024 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(a *models.Atom) (atom.Atom, error)

Types

type Atom

type Atom struct {
	atom.Atom
	// contains filtered or unexported fields
}

Atom defines the interface for treating Kubernetes pods as Caesium Atoms.

func (*Atom) CreatedAt

func (c *Atom) CreatedAt() time.Time

CreatedAt returns the UTC time the Atom was created.

func (*Atom) ID

func (c *Atom) ID() string

ID returns the ID of the Atom. This ID is identical to the Kubernetes pod name.

func (*Atom) Result

func (c *Atom) Result() atom.Result

Result returns the result of the Atom. This function maps pod container exit codes to Caesium Atom results.

func (*Atom) StartedAt

func (c *Atom) StartedAt() time.Time

StartedAt returns the UTC time the Atom was started.

func (*Atom) State

func (c *Atom) State() atom.State

State returns the state of the Atom. This function maps pod phases to Caesium Atom states.

func (*Atom) StoppedAt

func (c *Atom) StoppedAt() time.Time

StoppedAt returns the UTC time the Atom was stopped.

type Engine

type Engine interface {
	atom.Engine
}

Engine defines the interface for treating the Kubernetes API as a atom.Engine.

func NewEngine

func NewEngine(ctx context.Context, core ...corev1.CoreV1Interface) Engine

NewEngine creates a new instance of kubernetes.Engine for interacting with kubernetes.Atoms.

Jump to

Keyboard shortcuts

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