Support HTTP QUERY method (RFC 10008) end-to-end (proxy, plugins, body-keyed cache) #14944
ebremer
started this conversation in
Ideas and feature requests
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Summary
RFC 10008 defines QUERY — a safe, idempotent, cacheable HTTP method that carries a request body whose content defines the query. It fills the gap between GET (no body / URL-length limits) and POST-as-read (unsafe, uncacheable by default).
As an API gateway, Kong sits on the path of QUERY adoption. Clients and backends are starting to use QUERY (e.g. Node/undici, Tomcat, LWS Search/Type Index). Without explicit support, gateways often reject unknown methods, strip bodies, skip retries, or cache incorrectly.
Why Kong
QUERY only works end-to-end if Kong:
QUERYwith its body from a matching Route to the Gateway Service / upstream.Content-Type) per RFC 10008 §2.7.Today, Kong’s docs leave gaps:
GET,HEAD,PUT,DELETE,OPTIONS, andTRACE. QUERY is not included, so QUERY is treated like a non-idempotent method and will not be retried by default.Ask
Please support RFC 10008 across Kong Gateway, in particular:
1. Proxy / routing
QUERYand proxy method + body to the upstream (HTTP/1.1, HTTP/2, HTTP/3 as applicable).methods: allowQUERYin the methods list; document it alongside GET/POST/….2. Service retries
QUERYto the idempotent retry set used on connect/read/write timeout failures (withGET,HEAD,PUT,DELETE,OPTIONS,TRACE).3. Plugins that special-case methods
Audit method-sensitive plugins so QUERY is handled correctly, e.g.:
QUERYdistinctly.4. Proxy Cache / Proxy Cache Advanced
QUERYin configurable request methods if the plugin whitelists methods).Content-Type/ relevant representation metadata) per §2.7.method | request | query_params | headers | …) is not enough for QUERY.Bypassif body not buffered).All reactions