Help us shape the future of Go! Take the 2026 Go Developer Survey

status

package
v1.1.4 Latest Latest
Warning

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

Go to latest
Published: Dec 12, 2024 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ReasonOlderGatewayClassExists gwapiv1.GatewayClassConditionReason = "OlderGatewayClassExists"

	MsgOlderGatewayClassExists   = "Invalid GatewayClass: another older GatewayClass with the same Spec.Controller exists"
	MsgValidGatewayClass         = "Valid GatewayClass"
	MsgGatewayClassInvalidParams = "Invalid parametersRef"
)

Variables

View Source
var GatewaySupportedFeatures = getSupportedFeatures(conformance.EnvoyGatewaySuite, conformance.SkipTests)

GatewaySupportedFeatures is a list of supported Gateway-API features, based on the running conformance tests suite.

Functions

func Error2ConditionMsg

func Error2ConditionMsg(err error) string

Error2ConditionMsg format the error string to a Status condition message. * Convert the first letter to capital * Append "." to the string if it doesn't exist

func MergeConditions

func MergeConditions(conditions []metav1.Condition, updates ...metav1.Condition) []metav1.Condition

MergeConditions adds or updates matching conditions, and updates the transition time if details of a condition have changed. Returns the updated condition array.

func SetAcceptedForPolicyAncestors

func SetAcceptedForPolicyAncestors(policyStatus *gwapiv1a2.PolicyStatus, ancestorRefs []gwapiv1a2.ParentReference, controllerName string)

SetAcceptedForPolicyAncestors sets accepted conditions for each ancestor reference if it is unset.

func SetConditionForPolicyAncestor

func SetConditionForPolicyAncestor(policyStatus *gwapiv1a2.PolicyStatus, ancestorRef gwapiv1a2.ParentReference, controllerName string,
	conditionType gwapiv1a2.PolicyConditionType, status metav1.ConditionStatus, reason gwapiv1a2.PolicyConditionReason, message string, generation int64,
)

func SetConditionForPolicyAncestors

func SetConditionForPolicyAncestors(policyStatus *gwapiv1a2.PolicyStatus, ancestorRefs []gwapiv1a2.ParentReference, controllerName string,
	conditionType gwapiv1a2.PolicyConditionType, status metav1.ConditionStatus, reason gwapiv1a2.PolicyConditionReason, message string, generation int64,
)

func SetGatewayClassAccepted

func SetGatewayClassAccepted(gc *gwapiv1.GatewayClass, accepted bool, reason, msg string) *gwapiv1.GatewayClass

SetGatewayClassAccepted inserts or updates the Accepted condition for the provided GatewayClass.

func SetGatewayListenerStatusCondition

func SetGatewayListenerStatusCondition(gateway *gwapiv1.Gateway, listenerStatusIdx int,
	conditionType gwapiv1.ListenerConditionType, status metav1.ConditionStatus, reason gwapiv1.ListenerConditionReason, message string,
)

func SetProgrammedForEnvoyPatchPolicy

func SetProgrammedForEnvoyPatchPolicy(s *gwapiv1a2.PolicyStatus)

SetProgrammedForEnvoyPatchPolicy sets programmed conditions for each ancestor reference in policy status if it is unset.

func SetResolveErrorForPolicyAncestors

func SetResolveErrorForPolicyAncestors(policyStatus *gwapiv1a2.PolicyStatus, ancestorRefs []gwapiv1a2.ParentReference, controllerName string, generation int64, resolveErr *PolicyResolveError)

func SetResourceNotFoundErrorForEnvoyPatchPolicy

func SetResourceNotFoundErrorForEnvoyPatchPolicy(s *gwapiv1a2.PolicyStatus, notFoundResources []string)

func SetRouteStatusCondition

func SetRouteStatusCondition(route *gwapiv1.RouteStatus, routeParentStatusIdx int, routeGeneration int64,
	conditionType gwapiv1.RouteConditionType, status metav1.ConditionStatus, reason gwapiv1.RouteConditionReason, message string,
)

func SetTranslationErrorForEnvoyPatchPolicy

func SetTranslationErrorForEnvoyPatchPolicy(s *gwapiv1a2.PolicyStatus, errMsg string)

func SetTranslationErrorForPolicyAncestors

func SetTranslationErrorForPolicyAncestors(policyStatus *gwapiv1a2.PolicyStatus, ancestorRefs []gwapiv1a2.ParentReference, controllerName string, generation int64, errMsg string)

func UpdateBackendStatusAcceptedCondition

func UpdateBackendStatusAcceptedCondition(be *egv1a1.Backend, accepted bool, msg string) *egv1a1.Backend

UpdateBackendStatusAcceptedCondition updates the status condition for the provided Backend based on the accepted state.

func UpdateGatewayListenersNotValidCondition

func UpdateGatewayListenersNotValidCondition(gw *gwapiv1.Gateway, reason gwapiv1.GatewayConditionReason, status metav1.ConditionStatus, msg string) *gwapiv1.Gateway

func UpdateGatewayStatusAcceptedCondition

func UpdateGatewayStatusAcceptedCondition(gw *gwapiv1.Gateway, accepted bool) *gwapiv1.Gateway

UpdateGatewayStatusAcceptedCondition updates the status condition for the provided Gateway based on the accepted state.

func UpdateGatewayStatusProgrammedCondition

func UpdateGatewayStatusProgrammedCondition(gw *gwapiv1.Gateway, svc *corev1.Service, deployment *appsv1.Deployment, nodeAddresses ...string)

UpdateGatewayStatusProgrammedCondition updates the status addresses for the provided gateway based on the status IP/Hostname of svc and updates the Programmed condition based on the service and deployment state.

Types

type PolicyResolveError

type PolicyResolveError struct {
	Reason  gwapiv1a2.PolicyConditionReason
	Message string
	// contains filtered or unexported fields
}

Jump to

Keyboard shortcuts

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