Fork me on GitHub
#reitit
<
2023-02-05
>
DrLj贸tsson17:02:16

Is there a way to restrict the size of file uploads, during the upload? So the request is denied before the file reaches the route handler.

dharrigan21:02:17

Yes, I think there is. When you get back (and hold on to) a Server def, you can do this (.setAttribute server "org.eclipse.jetty.server.Request.maxFormContentSize" 10000)

dharrigan21:02:43

(assuming 'natch, you're using jetty) 馃檪

DrLj贸tsson22:02:35

Not using jetty, but this is a reason to switch. Thanks!

馃憤 2