neiam
/feedpug
feedpub
public · Issues · Pulls · Labels · Forks · Compare · Actions success · Badges · Packages
⭐
Log in to mark this repository.
Start PromEx after the Repo, not before it
07b612e · Gabriel Morell · 2026-08-25 02:59
Message
{commit_body(@commit)}
Files changed
modified
lib/feed_pug/application.ex
+5
−1
@@ -12,10 +12,14 @@ defmodule FeedPug.Application do
| 12 | 12 | children = |
| 13 | 13 | [ |
| 14 | 14 | FeedPugWeb.Telemetry, |
| 15 | + FeedPug.Repo, | |
| 16 | + # After the Repo, not before it: FeedPug.PromEx.Plugins.Library polls | |
| 17 | + # the database, and PromEx runs every poller once as it starts. Ahead | |
| 18 | + # of the Repo that first poll can only fail, logging a warning on every | |
| 19 | + # boot and leaving the gauges empty until the next tick. | |
| 15 | 20 | FeedPug.PromEx, |
| 16 | 21 | # The metrics listener, on its own port — see FeedPug.MetricsPlug. |
| 17 | 22 | {Bandit, plug: FeedPug.MetricsPlug, scheme: :http, port: 9568}, |
| 18 | − FeedPug.Repo, | |
| 19 | 23 | {DNSCluster, query: Application.get_env(:feed_pug, :dns_cluster_query) || :ignore} |
| 20 | 24 | ] ++ |
| 21 | 25 | cluster_children(topologies) ++ |
Parents: d7c0ce0