metricstrait

package
v1.0.4 Latest Latest
Warning

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

Go to latest
Published: Dec 17, 2021 License: UPL-1.0 Imports: 25 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MutateAnnotations

func MutateAnnotations(trait *vzapi.MetricsTrait, workload *unstructured.Unstructured, traitDefaults *vzapi.MetricsTraitSpec, annotations map[string]string) map[string]string

MutateAnnotations mutates annotations with values used by the scraper config. Annotations are either set or removed depending on the state of the trait.

func MutateLabels

func MutateLabels(trait *vzapi.MetricsTrait, workload *unstructured.Unstructured, labels map[string]string) map[string]string

MutateLabels mutates the labels associated with a related resources.

Types

type Reconciler

type Reconciler struct {
	client.Client
	Log     logr.Logger
	Scheme  *runtime.Scheme
	Scraper string
}

Reconciler reconciles a MetricsTrait object

func (*Reconciler) NewTraitDefaultsForCOHWorkload

func (r *Reconciler) NewTraitDefaultsForCOHWorkload(ctx context.Context, workload *unstructured.Unstructured) (*vzapi.MetricsTraitSpec, error)

NewTraitDefaultsForCOHWorkload creates metrics trait default values for a Coherence workload.

func (*Reconciler) NewTraitDefaultsForGenericWorkload

func (r *Reconciler) NewTraitDefaultsForGenericWorkload() (*vzapi.MetricsTraitSpec, error)

NewTraitDefaultsForGenericWorkload creates metrics trait default values for a containerized workload.

func (*Reconciler) NewTraitDefaultsForWLSDomainWorkload

func (r *Reconciler) NewTraitDefaultsForWLSDomainWorkload(ctx context.Context, workload *unstructured.Unstructured) (*vzapi.MetricsTraitSpec, error)

NewTraitDefaultsForWLSDomainWorkload creates metrics trait default values for a WLS domain workload.

func (*Reconciler) Reconcile

func (r *Reconciler) Reconcile(req ctrl.Request) (ctrl.Result, error)

Reconcile reconciles a metrics trait with related resources +kubebuilder:rbac:groups=oam.verrazzano.io,resources=metricstraits,verbs=get;list;watch;create;update;patch;delete +kubebuilder:rbac:groups=oam.verrazzano.io,resources=metricstraits/status,verbs=get;update;patch

func (*Reconciler) SetupWithManager

func (r *Reconciler) SetupWithManager(mgr ctrl.Manager) error

SetupWithManager creates a controller and adds it to the manager

Jump to

Keyboard shortcuts

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