stop_listener(Name :: ranch:ref()) -> ok | {error, not_found}.
cowboy:stop_listener - Stop the given listener
stop_listener(Name :: ranch:ref()) -> ok | {error, not_found}.
Stop a previously started listener.
Alias of ranch:stop_listener(3).
The name of the listener to be stopped.
The name of the listener is the first argument given to the cowboy:start_clear(3), cowboy:start_tls(3) or ranch:start_listener(3) function.
The atom ok
is returned on success.
The {error, not_found}
tuple is returned when the listener does not exist.
ok = cowboy:stop_listener(example).
cowboy(3), cowboy:start_clear(3), cowboy:start_tls(3), ranch(3), ranch:start_listener(3)
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.