Skip to content

Commit 8e81340

Browse files
author
Kate Osborn
committed
Update SnippetFilter validation rules in enhancement proposal
1 parent 964877f commit 8e81340

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

docs/proposals/advanced-nginx-extensions.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -445,6 +445,21 @@ one `http` snippet with multiple `http` snippets scattered around in the spec.
445445

446446
NGF will not validate the values of snippets. See the next section.
447447

448+
When a SnippetsFilter is specified in a routing rule and one of the following is true:
449+
450+
- the SnippetsFilter does not exist
451+
- the SnippetsFilter referenced is invalid
452+
- the same SnippetsFilter is referenced multiple times
453+
454+
the filter MUST NOT be skipped. Instead, requests that would have been processed by that filter MUST receive a 500 HTTP error code response.
455+
In addition, the `ResolvedRefs` condition should be set to `False` with one of the following reasons:
456+
457+
- `FilterNotFound`
458+
- `InvalidFilter`
459+
460+
These reasons are not defined in the Gateway API library, so they will need to be added and documented.
461+
In addition, the `Accepted` route condition should be set to `True`.
462+
448463
#### NGINX Values
449464

450465
An invalid snippet can break NGINX config. When this happens, NGINX will continue to use the last valid configuration.

0 commit comments

Comments
 (0)