How to configure Jetty in Duct to accept larger headers? Error message when sending a request with cookies that are more than the 8kb default:
10:20:40.277 WARN org.eclipse.jetty.http.HttpParser - Header is too large 8193>8192
Ah it’s a Ring Jetty Adapter, maybe explicitly add the key
{:duct.server.http/jetty
{:port 3000
:handler (fn [request]
{:status 200
:headers {"Content-Type" "text/plain"}
:body "Hello World"})}}
and configure thereAnd indeed also contains
:request-header-size - the maximum size of a request header (default 8192)
:response-header-size - the maximum size of a response header (default 8192):duct.module.web/api {}
:duct.server.http/jetty {:port 3000
:response-header-size 16384
:request-header-size 16384}}
;;=>
10:35:32.432 INFO org.eclipse.jetty.server.Server - Started @28171ms
Execution error (AssertionError) at integrant.core/prep (core.cljc:412).
Assert failed: (map? config)What’s wrong?
Putting it in :duct.profile/base seems to work
:duct.server.http/jetty {:response-header-size 16384
:request-header-size 16384}