diff --git a/lib/sanbase/application/application.ex b/lib/sanbase/application/application.ex index bbf156e62..68f91a6b4 100644 --- a/lib/sanbase/application/application.ex +++ b/lib/sanbase/application/application.ex @@ -300,21 +300,12 @@ defmodule Sanbase.Application do # Start the clickhouse read-only repos for different plans clickhouse_readonly_per_plan_children, - # Start the PubSub - {Phoenix.PubSub, name: Sanbase.PubSub}, - - # Start the Presence - SanbaseWeb.Presence, - - # Start the endpoint when the application starts - SanbaseWeb.Endpoint, + # Start the Task Supervisor + {Task.Supervisor, [name: Sanbase.TaskSupervisor]}, # Star the API call service Sanbase.ApiCallLimit.ETS, - # Start the Task Supervisor - {Task.Supervisor, [name: Sanbase.TaskSupervisor]}, - # Start telegram rate limiter. Used both in web and alerts Sanbase.ExternalServices.RateLimiting.Server.child_spec( :telegram_bot_rate_limiting_server, @@ -338,6 +329,15 @@ defmodule Sanbase.Application do # used in test env to another one, this one is unused start_in(Sanbase.AvailableSlugs, [:dev, :prod]), + # Start the PubSub + {Phoenix.PubSub, name: Sanbase.PubSub}, + + # Start the Presence + SanbaseWeb.Presence, + + # Start the endpoint when the application starts + SanbaseWeb.Endpoint, + # Process that starts test-only deps start_in(Sanbase.TestSetupService, [:test]), Sanbase.EventBus.children()