Module custom_axum

Source
Expand description

Wrapper for Axum server to add timeouts.

Copyright (c) Eray Karatay (@programatik29).

See: https://gist.github.com/programatik29/36d371c657392fd7f322e7342957b6d1.

If a client opens a HTTP connection and it does not send any requests, the connection is closed after a timeout. You can test it with:

telnet 127.0.0.1 1212
Trying 127.0.0.1...
Connected to 127.0.0.1.
Escape character is '^]'.
Connection closed by foreign host.

If you want to know more about Axum and timeouts see https://github.com/josecelano/axum-server-timeout.

Structs§

TimeoutAcceptor
TimeoutBody
TimeoutService
TimeoutServiceFuture
TimeoutStream

Functions§

from_tcp_rustls_with_timeouts
from_tcp_with_timeouts