elixir-ecto / db_connection

Database connection behaviour
http://hexdocs.pm/db_connection/DBConnection.html
306 stars 113 forks source link

Move backoff into the repository #19

Closed josevalim closed 8 years ago

josevalim commented 8 years ago

I am considering if we should move backoff to the repository as db_connection_backoff.erl for two reasons:

  1. Solve it in a way that's compatible with old and new Erlang versions alike
  2. Remove one dependency

Thoughts?

josevalim commented 8 years ago

The dependency is probably alright, it is unlikely they will remove erlang:now() on Erlang 19.

josevalim commented 8 years ago

On the other hand it is so small that making it built-in makes a lot of sense.

fishcakez commented 8 years ago

We can remove the dependency sure. If we do this can we replace backoff_start with backoff_min? So that the first (random) backoff is random, not fixed.

On 23 January 2016 at 09:54, José Valim notifications@github.com wrote:

On the other hand it is so small that making it built-in makes a lot of sense.

— Reply to this email directly or view it on GitHub https://github.com/fishcakez/db_connection/issues/19#issuecomment-174166480 .

fishcakez commented 8 years ago

Perhaps we could add a rebar.config.script so that backoff supports rebar2?

josevalim commented 8 years ago

It is up to you. :) moving in is easier because we then don't worry about dep management.

José Valimwww.plataformatec.com.br http://www.plataformatec.com.br/Founder and Director of R&D