From c9409146fa69f84a839f25284f2e93e77b8b30db Mon Sep 17 00:00:00 2001 From: Tsvetozar Penov Date: Thu, 21 Nov 2024 12:55:38 +0100 Subject: [PATCH] MOve endpoint further down in start sequence --- lib/sanbase/application/application.ex | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) 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()