Any suggestions on how to enforce a maximum duration on an incoming connection? ie. I want to issue a
Connection: close
after a connection has been used for over 1 minute.
s
s4nchez
07/30/2019, 3:59 PM
That’s done at the level of the server backend you’ve chosen to use (jetty, undertow, etc). We don’t control network level configuration via our API, but can try pointing you to the right docs if you let us know which backend you’re using.
j
Jordan Terrell
07/30/2019, 4:05 PM
Thanks. We are using undertow.
s
s4nchez
07/30/2019, 8:11 PM
@Jordan Terrell we currently don't have a way to configure the underlying Undertow out-of-the-box.
However, the core of our undertow integration is ~20 LOC, so you can easily replace with a custom implementation. I've put together a full example of how I'd put together a CustomUndertow server to cover your needs: https://gist.github.com/s4nchez/7f308483ac2402d9d429ff2b319b5b24
I hope that helps, otherwise please shout!