dom96 / jester

A sinatra-like web framework for Nim.
MIT License
1.56k stars 120 forks source link

Expose asynchttpserver maxBody setting #309

Closed noirscape closed 1 year ago

noirscape commented 1 year ago

Right now, Jester can't handle a post body larger than 8MB if asynchttpserver is used.

This is a configurable setting (maxBody) in newAsyncHttpServer, yet it is not currently exposed in the settings object. This PR adds maxBody to the settings object and passes it on to newAsyncHttpServer when serve is called.

The default value ( 8388608 ) is directly taken from the asynchttpserver docs.