• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

zentralopensource / zentral / 29831792481
89%

Build:
DEFAULT BRANCH: main
Ran 21 Jul 2026 12:59PM UTC
Jobs 1
Files 974
Run time 2min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

21 Jul 2026 12:20PM UTC coverage: 88.992% (+0.09%) from 88.9%
29831792481

push

github

np5
Recycle the DB connection for all preprocessors on a recoverable DB error

The preprocess worker runs a long-lived consumer loop with no request cycle,
so Django never recycles its pooled connection (CONN_HEALTH_CHECKS and
CONN_MAX_AGE are driven by the request_started / request_finished signals).
When a pooler/proxy drops an idle connection, the next commit raises
InterfaceError / OperationalError.

Only the inventory preprocessor caught that, and it reused the same dead
connection, so every following inventory_machine_snapshot message failed with
"connection already closed" until the process restarted — the worker
re-enqueued relentlessly and dead-lettered a large share of check-ins. The
other preprocessors (mdm, jamf, puppet, wsone) had no handling and just let the
worker crash.

Add iter_preprocessed_events(), a single entry point every queue backend uses
to run a preprocessor: it resolves the preprocessor for the routing key, yields
the events it produces, and on a recoverable DB error drops the dead connection
with close_old_connections() and raises RetryLater so the retry and the
following messages reconnect. The three backends (SQS, Pub/Sub, kombu) share it
instead of each duplicating the routing-key lookup and retry handling. The
inventory preprocessor no longer handles the DB error itself; it only re-raises
it so its deterministic-drop can't swallow it.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

41 of 41 new or added lines in 5 files covered. (100.0%)

47546 of 53427 relevant lines covered (88.99%)

0.89 hits per line

Jobs
ID Job ID Ran Files Coverage
1 29831792481.1 21 Jul 2026 12:59PM UTC 974
88.99
GitHub Action Run
Source Files on build 29831792481
  • Tree
  • List 974
  • Changed 5
  • Source Changed 4
  • Coverage Changed 5
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #29831792481
  • c4e1e9c0 on github
  • Prev Build on main (#29828977141)
  • Next Build on main (#29834550615)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc