Skip to content

Commit

Permalink
Bring back the inclusion of telemetry_poller in releases (#2324)
Browse files Browse the repository at this point in the history
The `runtime: false` option in mix.exs was the wrong one to use: it
excluded the dependency from release packaging, resulting in the release
startup failure when `ELECTRIC_USAGE_REPORTING=true`.

The correct way to make telemetry_poller's default reporting disabled is
to configure it as such.

Fixes #2323.
  • Loading branch information
alco authored Feb 11, 2025
1 parent 546a78d commit 3867309
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/funny-hairs-grab.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@core/sync-service": patch
---

Fix the startup failure problem caused by broken release packaging.
3 changes: 3 additions & 0 deletions packages/sync-service/config/runtime.exs
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,9 @@ if !is_nil(sentry_dsn) do
dsn: sentry_dsn
end

# Disable the default telemetry_poller process since we start our own in `Electric.Telemetry`.
config :telemetry_poller, default: false

service_name = env!("ELECTRIC_SERVICE_NAME", :string, "electric")
instance_id = env!("ELECTRIC_INSTANCE_ID", :string, Electric.Utils.uuid4())
version = Electric.version()
Expand Down
2 changes: 1 addition & 1 deletion packages/sync-service/mix.exs
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ defmodule Electric.MixProject do
{:sentry, "~> 10.0"},
{:telemetry_metrics_prometheus_core, "~> 1.1"},
{:telemetry_metrics_statsd, "~> 0.7"},
{:telemetry_poller, "~> 1.1", runtime: false},
{:telemetry_poller, "~> 1.1"},
{:tls_certificate_check, "~> 1.23"},
{:tz, "~> 0.27"}
],
Expand Down

0 comments on commit 3867309

Please sign in to comment.