You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/guides/advanced-configurations.md
+32Lines changed: 32 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -16,6 +16,38 @@ However, the controller utilizes [IMDS](https://docs.aws.amazon.com/AWSEC2/lates
16
16
17
17
- **If your cluster cannot access to IMDS.** ensure to specify the[configuration variables](environment.md) when installing the controller.
18
18
19
+
### Rule Priority Configuration
20
+
21
+
You can manually assign priorities to rules using the custom annotation `application-networking.k8s.aws/rule-{index}-priority`. This annotation allows you to explicitly set the priority forspecific rulesin your route configurations.
22
+
23
+
For example, to set priorities formultiple rulesin an HTTPRoute:
24
+
25
+
```yaml
26
+
apiVersion: gateway.networking.k8s.io/v1beta1
27
+
kind: HTTPRoute
28
+
metadata:
29
+
name: example-route
30
+
annotations:
31
+
application-networking.k8s.aws/rule-0-priority: "200"# First rule gets higher priority
32
+
application-networking.k8s.aws/rule-1-priority: "100" # Second rule gets lower priority
33
+
spec:
34
+
rules:
35
+
- matches: # This is rule[0]
36
+
- path:
37
+
type: PathPrefix
38
+
value: /api/v2
39
+
- matches: # This is rule[1]
40
+
- path:
41
+
type: PathPrefix
42
+
value: /api
43
+
```
44
+
45
+
The `{index}`in the annotation corresponds to the zero-based index of the rule in the rules array. In this example:
46
+
- `rule-0-priority: "200"` applies to the first rule matching `/api/v2`
47
+
- `rule-1-priority: "100"` applies to the second rule matching `/api`
48
+
49
+
Higher priority values indicate higher precedence, so requests to `/api/v2` will be matched by the first rule (priority 200) before the second rule (priority 100) is considered.
50
+
19
51
### IPv6 support
20
52
21
53
IPv6 address type is automatically used for your services and pods if
0 commit comments