Skip to content

Commit

Permalink
Resolve comments
Browse files Browse the repository at this point in the history
Signed-off-by: Lubron Zhan <lubronzhan@gmail.com>
  • Loading branch information
lubronzhan committed Jul 24, 2024
1 parent 039e83e commit b5fd797
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion changelogs/CHANGELOG-v1.29.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ It's possible that multiple HTTPRoutes will define the same Match conditions. In
- The oldest Route based on creation timestamp. For example, a Route with a creation timestamp of “2020-09-08 01:02:03” is given precedence over a Route with a creation timestamp of “2020-09-08 01:02:04”.
- The Route appearing first in alphabetical order (namespace/name) for example, foo/bar is given precedence over foo/baz.

With above ordering, any HTTPRoute that ranks lower, will be marked with below conditions accordionly
With above ordering, any HTTPRoute that ranks lower, will be marked with below conditions accordingly
1. If only partial rules under this HTTPRoute are conflicted, it's marked with `Accepted: True` and `PartiallyInvalid: true` Conditions and Reason: `RuleMatchPartiallyConflict`.
2. If all the rules under this HTTPRoute are conflicted, it's marked with `Accepted: False` Condition and Reason `RuleMatchConflict`.

Expand Down
2 changes: 1 addition & 1 deletion changelogs/unreleased/6566-lubronzhan-minor.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@ It's possible that multiple GRPCRoutes will define the same Match conditions. In
- The oldest Route based on creation timestamp. For example, a Route with a creation timestamp of “2020-09-08 01:02:03” is given precedence over a Route with a creation timestamp of “2020-09-08 01:02:04”.
- The Route appearing first in alphabetical order (namespace/name) for example, foo/bar is given precedence over foo/baz.

With above ordering, any GRPCRoute that ranks lower, will be marked with below conditions accordionly
With above ordering, any GRPCRoute that ranks lower, will be marked with below conditions accordingly:
1. If only partial rules under this GRPCRoute are conflicted, it's marked with `Accepted: True` and `PartiallyInvalid: true` Conditions and Reason: `RuleMatchPartiallyConflict`.
2. If all the rules under this GRPCRoute are conflicted, it's marked with `Accepted: False` Condition and Reason `RuleMatchConflict`.
6 changes: 3 additions & 3 deletions internal/dag/gatewayapi_processor_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1149,7 +1149,7 @@ func TestSortGRPCRoutes(t *testing.T) {
expected []*gatewayapi_v1.GRPCRoute
}{
{
name: "3 httproutes, with different timestamp, earlier one should be first ",
name: "3 grpcroutes, with different timestamp, earlier one should be first ",
m: map[types.NamespacedName]*gatewayapi_v1.GRPCRoute{
{
Namespace: "ns", Name: "name1",
Expand Down Expand Up @@ -1204,7 +1204,7 @@ func TestSortGRPCRoutes(t *testing.T) {
},
},
{
name: "3 httproutes with same creation timestamps, same namespaces, smaller name comes first",
name: "3 grpcroutes with same creation timestamps, same namespaces, smaller name comes first",
m: map[types.NamespacedName]*gatewayapi_v1.GRPCRoute{
{
Namespace: "ns", Name: "name3",
Expand Down Expand Up @@ -1259,7 +1259,7 @@ func TestSortGRPCRoutes(t *testing.T) {
},
},
{
name: "3 httproutes with same creation timestamp, smaller namespaces comes first",
name: "3 grpcroutes with same creation timestamp, smaller namespaces comes first",
m: map[types.NamespacedName]*gatewayapi_v1.GRPCRoute{
{
Namespace: "ns3", Name: "name1",
Expand Down

0 comments on commit b5fd797

Please sign in to comment.