Could not start application db_connection

Hello!
Had trouble when try to run mix ecto.migrate or start my phoenix app.
Got error:

[info] Application db_connection exited: DBConnection.App.start(:normal, []) returned an error: shutdown: failed to start child: DBConnection.Sojourn.Supervisor
    ** (EXIT) an exception was raised:
        ** (UndefinedFunctionError) function DBConnection.Sojourn.Supervisor.start_link/0 is undefined (module DBConnection.Sojourn.Supervisor is not available)
            DBConnection.Sojourn.Supervisor.start_link()
            (stdlib) supervisor.erl:379: :supervisor.do_start_child_i/3
            (stdlib) supervisor.erl:365: :supervisor.do_start_child/2
            (stdlib) supervisor.erl:349: anonymous fn/3 in :supervisor.start_children/2
            (stdlib) supervisor.erl:1157: :supervisor.children_map/4
            (stdlib) supervisor.erl:315: :supervisor.init_children/2
            (stdlib) gen_server.erl:374: :gen_server.init_it/2
            (stdlib) gen_server.erl:342: :gen_server.init_it/6
            (stdlib) proc_lib.erl:249: :proc_lib.init_p_do_apply/3

Everything worked well until yesterday afternoon. As db adapter use Mongo.Ecto, but I tried did it using postgres too.

You’ve likely upgraded to Ecto 3 and/or DBConnection 2 which replaced Sojourn pool support with an improved built-in queueing mechanism. You can remove :pool and other Sojourn options from your repo config and it should be good.

If its not it, please provide more information, e.g. versions of packages that you use.

2 Likes