github jmasarweh/UniFi-Insights-Plus v2.1.2
v2.1.2 — Fix CPU Spike on Container Boot

latest releases: v3.7.0, v3.6.3, v3.6.2...
3 months ago

Infrastructure

  • Fixed high CPU usage on container restart — v2.1.1 introduced a temporary PostgreSQL start/stop cycle on every boot for existing installs (to fix function ownership from #24). This caused PostgreSQL to start twice, doubling CPU usage during startup and causing page load delays on lower-powered hardware. (fixes #28)
  • Moved ownership fix into the application layer — Function ownership is now corrected via a one-time Unix socket connection at app startup (gated by system_config), eliminating the need for any extra PostgreSQL lifecycle operations in the entrypoint

Key Files Modified

  • entrypoint.sh — Removed temporary PostgreSQL start/stop from the existing-install boot path
  • receiver/db.py — Added _fix_function_ownership() method using local Unix socket; runs before schema migrations so CREATE OR REPLACE FUNCTION succeeds on first boot

Don't miss a new UniFi-Insights-Plus release

NewReleases is sending notifications on new releases.