check_metrics

package
v0.0.0-...-3d8ba93 Latest Latest
Warning

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

Go to latest
Published: Apr 7, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const CheckMetricsType = "check-metrics"

Variables

This section is empty.

Functions

func FromWorkflowStep

func FromWorkflowStep(from v1beta1.WorkflowStep) (apis.WorkflowStep, error)

func FromWorkflowSubStep

func FromWorkflowSubStep(from common.WorkflowSubStep) (apis.WorkflowStep, error)

Types

type CheckMetricsSpec

type CheckMetricsSpec struct {
	// Condition is an expression which determines if a measurement is considered successful. eg: >=0.95
	Condition *string `json:"condition"`
	// Duration defines the duration of time required for this step to be considered successful.
	Duration *string `json:"duration,omitempty"`
	// FailDuration is the duration of time that, if the check fails, will result in the step being marked as failed.
	FailDuration   *string         `json:"failDuration,omitempty"`
	MetricEndpoint *MetricEndpoint `json:"metricEndpoint,omitempty"`
	// Query is a raw prometheus query to perform
	Query *string `json:"query"`
}

CheckMetricsSpec struct for CheckMetricsSpec

func NewCheckMetricsSpec

func NewCheckMetricsSpec() *CheckMetricsSpec

NewCheckMetricsSpec is short for NewCheckMetricsSpecWithDefault which instantiates a new CheckMetricsSpec object. This constructor will only assign default values to properties that have it defined, but it doesn't guarantee that properties required by API are set

func NewCheckMetricsSpecEmpty

func NewCheckMetricsSpecEmpty() *CheckMetricsSpec

NewCheckMetricsSpecEmpty instantiates a new CheckMetricsSpec object with no properties set. This constructor will not assign any default values to properties.

func NewCheckMetricsSpecList

func NewCheckMetricsSpecList(ps ...*CheckMetricsSpec) []CheckMetricsSpec

NewCheckMetricsSpecs converts a list CheckMetricsSpec pointers to objects. This is helpful when the SetCheckMetricsSpec requires a list of objects

func NewCheckMetricsSpecWith

func NewCheckMetricsSpecWith(condition string, query string) *CheckMetricsSpec

NewCheckMetricsSpecWith instantiates a new CheckMetricsSpec object This constructor will make sure properties required by API are set. For optional properties, it will set default values if they have been defined. The set of arguments will change when the set of required properties is changed

func NewCheckMetricsSpecWithDefault

func NewCheckMetricsSpecWithDefault() *CheckMetricsSpec

NewCheckMetricsSpecWithDefault instantiates a new CheckMetricsSpec object This constructor will only assign default values to properties that have it defined, but it doesn't guarantee that properties required by API are set

func (CheckMetricsSpec) MarshalJSON

func (o CheckMetricsSpec) MarshalJSON() ([]byte, error)

func (CheckMetricsSpec) ToMap

func (o CheckMetricsSpec) ToMap() (map[string]interface{}, error)

type CheckMetricsWorkflowStep

type CheckMetricsWorkflowStep struct {
	Base       apis.WorkflowStepBase
	Properties CheckMetricsSpec
}

func CheckMetrics

func CheckMetrics(name string) *CheckMetricsWorkflowStep

func (*CheckMetricsWorkflowStep) Alias

func (*CheckMetricsWorkflowStep) Build

func (*CheckMetricsWorkflowStep) DefType

func (c *CheckMetricsWorkflowStep) DefType() string

func (*CheckMetricsWorkflowStep) DependsOn

func (c *CheckMetricsWorkflowStep) DependsOn(dependsOn []string) *CheckMetricsWorkflowStep

func (*CheckMetricsWorkflowStep) FromWorkflowStep

func (*CheckMetricsWorkflowStep) FromWorkflowSubStep

func (*CheckMetricsWorkflowStep) GetCondition

func (o *CheckMetricsWorkflowStep) GetCondition() string

GetCondition returns the Condition field value

func (*CheckMetricsWorkflowStep) GetConditionOk

func (o *CheckMetricsWorkflowStep) GetConditionOk() (*string, bool)

GetConditionOk returns a tuple with the Condition field value and a boolean to check if the value has been set.

func (*CheckMetricsWorkflowStep) GetDuration

func (o *CheckMetricsWorkflowStep) GetDuration() string

GetDuration returns the Duration field value if set, zero value otherwise.

func (*CheckMetricsWorkflowStep) GetDurationOk

func (o *CheckMetricsWorkflowStep) GetDurationOk() (*string, bool)

GetDurationOk returns a tuple with the Duration field value if set, nil otherwise and a boolean to check if the value has been set.

func (*CheckMetricsWorkflowStep) GetFailDuration

func (o *CheckMetricsWorkflowStep) GetFailDuration() string

GetFailDuration returns the FailDuration field value if set, zero value otherwise.

func (*CheckMetricsWorkflowStep) GetFailDurationOk

func (o *CheckMetricsWorkflowStep) GetFailDurationOk() (*string, bool)

GetFailDurationOk returns a tuple with the FailDuration field value if set, nil otherwise and a boolean to check if the value has been set.

func (*CheckMetricsWorkflowStep) GetMetricEndpoint

func (o *CheckMetricsWorkflowStep) GetMetricEndpoint() MetricEndpoint

GetMetricEndpoint returns the MetricEndpoint field value if set, zero value otherwise.

func (*CheckMetricsWorkflowStep) GetMetricEndpointOk

func (o *CheckMetricsWorkflowStep) GetMetricEndpointOk() (*MetricEndpoint, bool)

GetMetricEndpointOk returns a tuple with the MetricEndpoint field value if set, nil otherwise and a boolean to check if the value has been set.

func (*CheckMetricsWorkflowStep) GetQuery

func (o *CheckMetricsWorkflowStep) GetQuery() string

GetQuery returns the Query field value

func (*CheckMetricsWorkflowStep) GetQueryOk

func (o *CheckMetricsWorkflowStep) GetQueryOk() (*string, bool)

GetQueryOk returns a tuple with the Query field value and a boolean to check if the value has been set.

func (*CheckMetricsWorkflowStep) HasDuration

func (o *CheckMetricsWorkflowStep) HasDuration() bool

HasDuration returns a boolean if a field has been set.

func (*CheckMetricsWorkflowStep) HasFailDuration

func (o *CheckMetricsWorkflowStep) HasFailDuration() bool

HasFailDuration returns a boolean if a field has been set.

func (*CheckMetricsWorkflowStep) HasMetricEndpoint

func (o *CheckMetricsWorkflowStep) HasMetricEndpoint() bool

HasMetricEndpoint returns a boolean if a field has been set.

func (*CheckMetricsWorkflowStep) If

func (*CheckMetricsWorkflowStep) Inputs

func (*CheckMetricsWorkflowStep) Outputs

func (*CheckMetricsWorkflowStep) SetCondition

SetCondition sets field value

func (*CheckMetricsWorkflowStep) SetDuration

SetDuration gets a reference to the given string and assigns it to the duration field. Duration: Duration defines the duration of time required for this step to be considered successful.

func (*CheckMetricsWorkflowStep) SetFailDuration

SetFailDuration gets a reference to the given string and assigns it to the failDuration field. FailDuration: FailDuration is the duration of time that, if the check fails, will result in the step being marked as failed.

func (*CheckMetricsWorkflowStep) SetMetricEndpoint

SetMetricEndpoint gets a reference to the given MetricEndpoint and assigns it to the metricEndpoint field. MetricEndpoint:

func (*CheckMetricsWorkflowStep) SetQuery

SetQuery sets field value

func (*CheckMetricsWorkflowStep) Timeout

func (*CheckMetricsWorkflowStep) Validate

func (o *CheckMetricsWorkflowStep) Validate() error

Validate validates this CheckMetricsSpec 1. If the required properties are not set, this will return an error 2. If properties are set, will check if nested required properties are set

func (*CheckMetricsWorkflowStep) WorkflowStepName

func (c *CheckMetricsWorkflowStep) WorkflowStepName() string

type MetricEndpoint

type MetricEndpoint struct {
	String *string
}

MetricEndpoint - The HTTP address and port of the prometheus server

func StringAsMetricEndpoint

func StringAsMetricEndpoint(v *string) MetricEndpoint

StringAsMetricEndpoint is is a convenience function that returns string wrapped in MetricEndpoint

func (*MetricEndpoint) GetActualInstance

func (obj *MetricEndpoint) GetActualInstance() interface{}

Get the actual instance

func (MetricEndpoint) MarshalJSON

func (src MetricEndpoint) MarshalJSON() ([]byte, error)

Marshal data from the first non-nil pointers in the struct to JSON

func (*MetricEndpoint) UnmarshalJSON

func (dst *MetricEndpoint) UnmarshalJSON(data []byte) error

Unmarshal JSON data into one of the pointers in the struct

func (*MetricEndpoint) Validate

func (o *MetricEndpoint) Validate() error

Validate validates this MetricEndpoint

type NullableCheckMetricsSpec

type NullableCheckMetricsSpec struct {
	// contains filtered or unexported fields
}

func NewNullableCheckMetricsSpec

func NewNullableCheckMetricsSpec(val *CheckMetricsSpec) *NullableCheckMetricsSpec

func (*NullableCheckMetricsSpec) Get

func (*NullableCheckMetricsSpec) IsSet

func (v *NullableCheckMetricsSpec) IsSet() bool

func (NullableCheckMetricsSpec) MarshalJSON

func (v NullableCheckMetricsSpec) MarshalJSON() ([]byte, error)

func (*NullableCheckMetricsSpec) Set

func (*NullableCheckMetricsSpec) UnmarshalJSON

func (v *NullableCheckMetricsSpec) UnmarshalJSON(src []byte) error

func (*NullableCheckMetricsSpec) Unset

func (v *NullableCheckMetricsSpec) Unset()

type NullableMetricEndpoint

type NullableMetricEndpoint struct {
	// contains filtered or unexported fields
}

func NewNullableMetricEndpoint

func NewNullableMetricEndpoint(val *MetricEndpoint) *NullableMetricEndpoint

func (*NullableMetricEndpoint) Get

func (*NullableMetricEndpoint) IsSet

func (v *NullableMetricEndpoint) IsSet() bool

func (NullableMetricEndpoint) MarshalJSON

func (v NullableMetricEndpoint) MarshalJSON() ([]byte, error)

func (*NullableMetricEndpoint) Set

func (*NullableMetricEndpoint) UnmarshalJSON

func (v *NullableMetricEndpoint) UnmarshalJSON(src []byte) error

func (*NullableMetricEndpoint) Unset

func (v *NullableMetricEndpoint) Unset()

Jump to

Keyboard shortcuts

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