We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0fdb559 commit cecdc32Copy full SHA for cecdc32
lib/ecto/adapters/sqlite3/connection.ex
@@ -23,7 +23,7 @@ defmodule Ecto.Adapters.SQLite3.Connection do
23
# sleeping an amount of time which is a function of the pool_index
24
def handle_thundering_herd(opts) do
25
case Keyword.get(opts, :pool_index) do
26
- idx -> :timer.sleep(idx * @idx_connect_buffer)
+ idx when is_integer(idx) -> :timer.sleep(idx * @idx_connect_buffer)
27
nil -> :timer.sleep(:rand.uniform(@rand_connect_buffer))
28
end
29
0 commit comments