generated from kubernetes/kubernetes-template-project
-
Notifications
You must be signed in to change notification settings - Fork 480
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make gwctl ReferenceGrant aware. Capture any errors observed while co…
…nstructing the resource graph. (#3029) * Do not calculate effective policy for the Gateway if the GatewayClass is incorrect. For now, we only calculate effective policy once the references are corrected. * Use ReferenceGrants to determine if a cross-namespace reference from HTTPRoute to a Backend is valid. * Move ObjRef to common package with no internal dependency * Capture incorrect reference errors (like reference not found or not permitted) in the resourceModel. This will be available for consumption by the views. * fix backends printer test to work with reference grants. Also minimize test surface. * fixup! Use ReferenceGrants to determine if a cross-namespace reference from HTTPRoute to a Backend is valid. * fix: Correct the error message when we fail to parse label selector * fixup! Use ReferenceGrants to determine if a cross-namespace reference from HTTPRoute to a Backend is valid. * fixup! Do not calculate effective policy for the Gateway if the GatewayClass is incorrect.
- Loading branch information
1 parent
cd175ec
commit 654dde5
Showing
12 changed files
with
891 additions
and
434 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
/* | ||
Copyright 2024 The Kubernetes Authors. | ||
Licensed under the Apache License, Version 2.0 (the "License"); | ||
you may not use this file except in compliance with the License. | ||
You may obtain a copy of the License at | ||
http://www.apache.org/licenses/LICENSE-2.0 | ||
Unless required by applicable law or agreed to in writing, software | ||
distributed under the License is distributed on an "AS IS" BASIS, | ||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
See the License for the specific language governing permissions and | ||
limitations under the License. | ||
*/ | ||
|
||
package common | ||
|
||
// ObjRef defines a reference to a Kubernetes resource, using plain strings for | ||
// easier comparison. | ||
type ObjRef struct { | ||
Group string `json:",omitempty"` | ||
Kind string `json:",omitempty"` | ||
Name string `json:",omitempty"` | ||
Namespace string `json:",omitempty"` | ||
} |
Oops, something went wrong.