Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions apis/v1alpha2/grpcroute_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,13 @@ type GRPCRouteRule struct {
//
// Specifying a core filter multiple times has unspecified or
// implementation-specific conformance.
//
// If an implementation can not support a combinations of filters, they must clearly
// document that limitation. In cases where incompatible or unsupported
// filters are specified and cause the `Accepted` condition to be set to status
// `False`, implementations may use the `IncompatibleFilters` reason to specify
// this configuration error.
//
// Support: Core
//
// +optional
Expand Down
6 changes: 4 additions & 2 deletions apis/v1beta1/httproute_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -207,8 +207,10 @@ type HTTPRouteRule struct {
// All filters are expected to be compatible with each other except for the
// URLRewrite and RequestRedirect filters, which may not be combined. If an
// implementation can not support other combinations of filters, they must clearly
// document that limitation. In all cases where incompatible or unsupported
// filters are specified, implementations MUST add a warning condition to status.
// document that limitation. In cases where incompatible or unsupported
// filters are specified and cause the `Accepted` condition to be set to status
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this section cause the Accepted condition to be set to status False is because you might have a partially valid route, in that case it would still be Accepted=True so doesn't really make sense to set the IncompatibleFilters reason

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I ran into the same problem in #2155 where it would be really useful to be able to communicate "something's not quite right, but we're still able to at least partially reconcile this route". In that case it was if the timeout specified was more precise (ie ms or ns) than the underlying implementation could support.

// `False`, implementations may use the `IncompatibleFilters` reason to specify
// this configuration error.
//
// Support: Core
//
Expand Down
5 changes: 5 additions & 0 deletions apis/v1beta1/shared_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -252,6 +252,11 @@ const (
// reconciled the route.
RouteReasonPending RouteConditionReason = "Pending"

// This reason is used with the "Accepted" condition when there
// are incompatible filters present on a route rule (for example if
// the URLRewrite and RequestRedirect are both present on an HTTPRoute).
RouteReasonIncompatibleFilters RouteConditionReason = "IncompatibleFilters"

// This condition indicates whether the controller was able to resolve all
// the object references for the Route.
//
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 8 additions & 6 deletions config/crd/standard/gateway.networking.k8s.io_httproutes.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 5 additions & 4 deletions site-src/api-types/grpcroute.md
Original file line number Diff line number Diff line change
Expand Up @@ -184,10 +184,11 @@ Conformance levels are defined by the filter type:

Specifying a core filter multiple times has unspecified or custom conformance.

All filters are expected to be compatible with each other. If an implementation
cannot support other combinations of filters, they must clearly document that
limitation. In all cases where incompatible or unsupported filters are
specified, implementations MUST add a warning condition to status.
If an implementation can not support a combinations of filters, they must clearly
Copy link
Contributor

@arkodg arkodg Jun 28, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: cannot (is more widely used)

document that limitation. In cases where incompatible or unsupported
filters are specified and cause the `Accepted` condition to be set to status
`False`, implementations may use the `IncompatibleFilters` reason to specify
this configuration error.

#### BackendRefs (optional)

Expand Down
6 changes: 4 additions & 2 deletions site-src/api-types/httproute.md
Original file line number Diff line number Diff line change
Expand Up @@ -130,8 +130,10 @@ implementation-specific conformance.
All filters are expected to be compatible with each other except for the
URLRewrite and RequestRedirect filters, which may not be combined. If an
implementation can not support other combinations of filters, they must clearly
document that limitation. In all cases where incompatible or unsupported
filters are specified, implementations MUST add a warning condition to status.
document that limitation. In cases where incompatible or unsupported
filters are specified and cause the `Accepted` condition to be set to status
`False`, implementations may use the `IncompatibleFilters` reason to specify
this configuration error.

#### BackendRefs (optional)

Expand Down