shutdown(ConnPid) -> ok ConnPid :: pid()
gun:shutdown - Gracefully close the connection
shutdown(ConnPid) -> ok ConnPid :: pid()
Gracefully close the connection.
Gun will wait for up to closing_timeout
milliseconds before brutally closing the connection. The graceful shutdown mechanism varies between the different protocols:
The function returns immediately. The connection may therefore still be up for some time after this call.
Gun will not attempt to reconnect once graceful shutdown has been initiated.
The pid of the Gun connection process.
The atom ok
is returned.
ok = gun:shutdown(ConnPid).
Donate to Loïc Hoguin because his work on Cowboy, Ranch, Gun and Erlang.mk is fantastic:
Recurring payment options are also available via GitHub Sponsors. These funds are used to cover the recurring expenses like food, dedicated servers or domain names.