Skip to content

fix: make telemetry resilient to fara.questdb.io failures#510

Merged
bluestreak01 merged 5 commits intomainfrom
vi_fix_telem
Dec 19, 2025
Merged

fix: make telemetry resilient to fara.questdb.io failures#510
bluestreak01 merged 5 commits intomainfrom
vi_fix_telem

Conversation

@bluestreak01
Copy link
Copy Markdown
Member

Summary

  • Adds exponential backoff retry (5 attempts with 1s, 2s, 4s, 8s, 16s delays, capped at 30s) when POSTing telemetry to fara.questdb.io
  • Ensures the hourly telemetry loop continues even after max retries are exhausted
  • Fixes startup failure case: if /config endpoint fails, the loop still starts and retries next hour
  • Extracts magic numbers into named constants (MAX_RETRIES, RETRY_BASE_DELAY_MS, etc.)
  • Adds unit tests for the startTelemetry epic

Problem

Previously, a single failed POST to fara.questdb.io would permanently stop the telemetry loop until the user refreshed the page. This meant transient network issues or brief fara outages would cause telemetry gaps.

Test plan

  • npm run build passes
  • npm run typecheck passes
  • npm run test:unit passes (31 tests including 6 new telemetry tests)
  • npm run lint passes

🤖 Generated with Claude Code

bluestreak01 and others added 5 commits December 18, 2025 19:10
Previously, if the telemetry POST to fara.questdb.io failed, the hourly
telemetry loop would stop permanently until the user refreshed the page.

This change adds:
- Exponential backoff retry (5 attempts: 1s, 2s, 4s, 8s, 16s delays)
- Loop continuation after max retries exhausted
- Graceful handling when /config endpoint fails at startup
- Named constants for retry parameters

Also adds unit tests for the telemetry epic.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <[email protected]>
- Use Subject instead of Observable for StateObservable
- Use async/await instead of done callback

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <[email protected]>
@bluestreak01 bluestreak01 merged commit cb7ae58 into main Dec 19, 2025
3 checks passed
@bluestreak01 bluestreak01 deleted the vi_fix_telem branch December 19, 2025 23:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants