version

package
v1.0.4 Latest Latest
Warning

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

Go to latest
Published: Oct 26, 2022 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Version is the Operator's version
	Version = "1.0.4"

	// AstarteVersionConstraintString represents the range of supported Astarte versions for this Operator.
	// If the Astarte version falls out of this range, reconciliation will be immediately aborted.
	AstarteVersionConstraintString = ">= 0.10.0, < 1.1.0"

	// SnapshotVersion represents the name of the master/snapshot version, which can or cannot be installed
	// by this cluster
	SnapshotVersion = "snapshot"
)

Variables

View Source
var (
	// ErrConstraintNotSatisfied means the check happened correctly, but the constraint wasn't satisfied
	ErrConstraintNotSatisfied = errors.New("constraint not satisfied")
)

Functions

func CanManageSnapshot added in v1.0.0

func CanManageSnapshot() bool

CanManageSnapshot returns whether the Operator can handle snapshot or not. We assume it can in case the Operator itself is a prerelease

func CanManageVersion added in v1.0.0

func CanManageVersion(v string) bool

CanManageVersion returns whether the Operator can manage the given version.

func CheckConstraintAgainstAstarteComponentVersion added in v1.0.0

func CheckConstraintAgainstAstarteComponentVersion(constraint, componentVersion, astarteVersion string) error

CheckConstraintAgainstAstarteComponentVersion checks a constraint against a specialized Astarte component version

func CheckConstraintAgainstAstarteVersion added in v1.0.0

func CheckConstraintAgainstAstarteVersion(constraint, v string) error

CheckConstraintAgainstAstarteVersion validates a given Astarte version against a given constraint. Returns nil if the constraint is satisfied, an error otherwise

func GetAstarteSemanticVersionFrom added in v1.0.0

func GetAstarteSemanticVersionFrom(v string) (*semver.Version, error)

GetAstarteSemanticVersionFrom returns a semver object out of an Astarte version string, returning an error also if the version does not adhere to constraints or isn't supported by the Operator

func GetVersionForAstarteComponent added in v1.0.0

func GetVersionForAstarteComponent(astarteVersion, componentVersion string) string

GetVersionForAstarteComponent returns the version for a given Astarte Component

Types

This section is empty.

Jump to

Keyboard shortcuts

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