forked from AkkomaGang/akkoma
naming
This commit is contained in:
parent
e605e79df9
commit
7d68924e4f
1 changed files with 2 additions and 2 deletions
|
@ -54,7 +54,7 @@ def open(%URI{} = uri, name, opts) do
|
|||
if Connections.count(name) < opts[:max_connection] do
|
||||
do_open(uri, opts)
|
||||
else
|
||||
try_do_open(name, uri, opts)
|
||||
close_least_used_and_do_open(name, uri, opts)
|
||||
end
|
||||
|
||||
if is_pid(conn_pid) do
|
||||
|
@ -159,7 +159,7 @@ defp add_http2_opts(opts, "https", tls_opts) do
|
|||
|
||||
defp add_http2_opts(opts, _, _), do: opts
|
||||
|
||||
defp try_do_open(name, uri, opts) do
|
||||
defp close_least_used_and_do_open(name, uri, opts) do
|
||||
Logger.debug("try to open conn #{Connections.compose_uri_log(uri)}")
|
||||
|
||||
with [{close_key, least_used} | _conns] <-
|
||||
|
|
Loading…
Reference in a new issue