On November 15, 2026, pm2 jlist reported 8 online of 9 processes across my Oracle Cloud host, while algom-stream sat in waiting restart with 4403 restarts and an uptime of 0d. Right beside it, its sibling ingest worker algom-poll showed 0 restarts, up 1d, consuming 78 MB of memory. The process supervisor did exactly what it was configured to do: whenever algom-stream dropped its execution loop, the runner spawned it again, burned through process lifecycles, and masked a systemic ingestion failure behind nominal server uptime.
Relying on process supervisor state to indicate service health is a fatal assumption. If your status screen reports green lights because 8 processes are active, you will miss the single service trapped in a restart cycle until your pipelines starve.
The Measured Disconnect Between Stream and Poller
The host runs nine services managed by PM2. Six backend application processes and two system utilities were running without disruption when the telemetry snapshot was captured:
pm2-logrotate: online, 0 restarts, up 1d, 82 MBdragontrade-dashboard: online, 0 restarts, up 1d, 77 MBcto-aipa: online, 0 restarts, up 1d, 218 MBdragontrade-main: online, 0 restarts, up 1d, 181 MBalgom-poll: online, 0 restarts, up 1d, 78 MBwhitespace: online, 0 restarts, up 1d, 112 MBn8n: online, 0 restarts, up 1d, 399 MBserpapi-jobs: online, 0 restarts, up 1d, 108 MBalgom-stream: waiting restart, 4403 restarts, up 0d
Both algom-stream and algom-poll handle related data operations for the system. Yet algom-poll ran for 1d consuming 78 MB without crashing once, while algom-stream entered an unbuffered restart cycle that triggered 4403 times.
The operational architecture explains the difference. Polling workers make transactional, bounded requests on a scheduled interval. A failure during a single polling pass throws an exception, logs an entry, exits gracefully, or sleeps until the next pass runs. The process stays running. Streaming workers, however, attempt to maintain persistent connections. When a stream drops, unhandled socket disconnections or unmanaged promise rejections bubble directly to the top of the event loop. Without strict restart backoff and top-level error trapping, PM2 treats the exit as an abnormal termination and immediately reboots the process. If the remote endpoint rejects the reconnection or drops the handshake, the process restarts repeatedly, hitting 4403 restarts while its sibling stays up.
Why Process Supervisors Hide Dead Code Paths
Process runners like PM2 ensure that temporary faults do not take down an entire stack. If an unexpected memory spike occurs, restarting the process preserves overall availability. But this convenience turns against you when a permanent failure state masquerades as transient instability.
When algom-stream dropped into waiting restart, the machine did not raise an alert on CPU exhaustion or disk failure. Other services functioned continuously:
deal-digest.logrecorded 32 live job deals processed to disk across stages including 14 qualifiedtobuy, 1 decisionmakerboughtin, 6 contractsent, and 11 appointmentscheduled.espaluz-truth.logcompleted recurring database synchronizations, outputting 59 rows to truth_people across consecutive batches.cita-sort.logevaluated schedules across 3 boards cleanly.concierge-selftest.logcompleted 5 checks in 4352ms.
The server had capacity. The network allowed external traffic. Yet algom-stream remained broken because automatic restarts bypass error discovery. A developer inspecting a dashboard that counts running processes sees 8 online nodes and assumes normal operations. Meanwhile, the stream worker never stays live long enough to establish state, write buffers, or notify downstream consumers.
The Cost of Silent Restarts on Downstream Workflows
When an ingest stream churns through 4403 restarts, upstream queues fill or silently discard events. In an autonomous business runtime, background services rely on persistent streams to trigger analysis, update records, and keep audit tracks accurate.
Across our operational pipelines, disconnected data channels degrade system decisions. In our CRM pipelines running through the HubSpot deals search API, we track 135 deals at contractsent and 0 closed won. In our messaging interfaces, apply-queue.log logged:
✓ sent to Telegram (1 new)
sunk by kit verdict: 12
✓ sent to Telegram (1 new)
While downstream jobs like
followup-radar.log scanned external mail accounts—tracking 776 inbox records in gmail and 209 in zoho—any process upstream that depends on continuous streaming data drops out of sync the moment a crash loop starts.
If a worker is restarting every few seconds, log files become flooded with startup boilerplate. Diagnostic logs overwrite actionable historical stack traces unless rotation policies are strictly set. Because pm2-logrotate was active and stable at 82 MB, host memory was protected, but the diagnostic signal inside the worker log was buried under thousands of duplicate boot lines.
How to Prevent algom-stream Crash Loop PM a Measured Figure Restart
To prevent a worker process from accumulating thousands of restarts while its sibling processes remain operational, configure strict execution rules in your supervisor configuration:
1. Enforce Minimum Uptime Thresholds: Use min_uptime in your PM2 ecosystem file. If a script fails before running for a required threshold (such as 10s or 20s), PM2 identifies it as unstable rather than executing a rapid reboot cycle.
2. Implement Exponential Backoff: By setting exp_backoff_restart_delay, you force the supervisor to wait progressively longer between restart attempts. This prevents thousands of blind restart cycles from thrashing host resources and filling process logs.
3. Decouple Stream Handlers from Process Life: In Node.js or Python streaming scripts, connection disconnects must never cause the main runtime loop to exit with a non-zero status code. Unhandled rejections must be captured inside the network transport layer, triggering an internal backoff and retry loop while keeping the PM2 process status cleanly online.
4. Monitor Restart Counts as P0 Incidents: A high restart count is an active failure. A monitoring check that flags any process with restarts exceeding 10 within an hour alerts the operator before the counter reaches 4403.
Frequently Asked Questions
Q: Why did algom-poll survive with 0 restarts while algom-stream crashed 4403 times?
A: algom-poll runs discrete, bounded polling executions that catch request errors within local try/catch blocks, keeping the process online at 78 MB. algom-stream maintains a persistent socket connection where uncaught disconnections or unhandled promise rejections bubble up to the runtime root, forcing PM2 to restart the process.
Q: Does PM2 stop restarting a process after a specific number of crashes?
A: By default, PM2 will restart a crashing process indefinitely unless you explicitly configure the max_restarts directive or combine min_uptime with backoff limits in your ecosystem configuration file.
Q: Did the high restart count on algom-stream degrade memory on the host?
A: No. PM2 tracks and cleans up child process allocations on exit; algom-stream registered 0d uptime and minimal footprint, while stable services like n8n used 399 MB and cto-aipa used 218 MB without memory exhaustion.
— Elena Revicheva · AIdeazz AI Lab · Portfolio · Professional Outlook (PDF)