Conversation
New CLI tool at cloud/tools/bstack/ for instant production diagnostics: - bstack health: all-region health check with uptime monitors - bstack diagnostics: GC probes, event loop gaps, MongoDB, operation budget - bstack crash-timeline: what happened before a crash - bstack memory: RSS trend with growth rate and time-to-crash estimate - bstack gc/gaps/budget/slow-queries/cache: focused analysis per feature - bstack incidents: recent uptime incidents - bstack sources: list all BetterStack resources - bstack sql: raw ClickHouse SQL queries config.ts: complete inventory of all BetterStack source IDs, collector IDs, dashboard IDs, uptime monitors, region configs, and diagnostic features. Usage: cd cloud/tools/bstack && bun run bstack.ts <command> Requires: BETTERSTACK_USERNAME, BETTERSTACK_PASSWORD, BETTERSTACK_API_TOKEN Issue: cloud/issues/064-bstack-cli/spike.md
…27-28 12 open items tracked: - Cloudflare LB wrong domain (mobile uses mentra.glass, LB config on mentraglass.com) - France/East Asia need redeploy for new BetterStack source - MongoDB users.findOne 3.4s spike (definitive event loop gap cause) - SDK auth still hits DB (intentional tradeoff) - Bun runtime memory issues (known, monitoring) - MongoDB callback storm theory (needs proof) - Per-region uptime monitors (not set up) - Dashboard alerts (not set up) - Multi-region dashboards (only US Central) - Mobile reconnect improvements - MEMORY_TELEMETRY_ENABLED still not flipped - Cherry-pick hotfixes into dev Plus complete inventory of what was shipped and tools available.
…ff for next session
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
📋 PR Review Helper📱 Mobile App Build⏳ Waiting for build... 🕶️ ASG Client Build⏳ Waiting for build... 🔀 Test Locallygh pr checkout 2351 |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: ea76b518d3
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
cloud/tools/bstack/config.ts
Outdated
| if (!API_TOKEN) { | ||
| console.error("❌ BETTERSTACK_API_TOKEN not set."); | ||
| console.error(" This is the management API token from BetterStack → Integrations → API."); | ||
| process.exit(1); |
There was a problem hiding this comment.
Avoid exiting process when uptime token is missing
cmdHealth wraps uptime monitor fetching in try/catch and prints a fallback message, but validateApiToken() calls process.exit(1) directly, so the catch path is never reached. This makes bstack health terminate with a non-zero exit whenever BETTERSTACK_API_TOKEN is unset, even though region health checks already completed and the code intends monitor fetching to be optional.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Fixed in 407bb40. validateApiToken() now throws an error instead of calling process.exit(1). cmdHealth checks API_TOKEN before calling fetchUptime() and prints a fallback message if it's not set, so region health checks still complete successfully.
…ate 065 tracking with DNS findings and current status
…udit, observability gaps, BetterStack evidence
…mmary at disposal time
…objects/10min inside stable sessions, proposed observability O1-O3
…for Vector log collection
…d JSON to stdout for Vector collection, fixes createFilteredStream double-parse
Deploying mentra-live-ota-site with
|
| Latest commit: |
4b5d6fc
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://c25af164.mentra-live-ota-site.pages.dev |
| Branch Preview URL: | https://cloud-064-bstack-cli.mentra-live-ota-site.pages.dev |
Deploying mentra-store-dev with
|
| Latest commit: |
4b5d6fc
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://5c4bae06.augmentos-appstore-2.pages.dev |
| Branch Preview URL: | https://cloud-064-bstack-cli.augmentos-appstore-2.pages.dev |
Deploying dev-augmentos-console with
|
| Latest commit: |
4b5d6fc
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://c75175dc.dev-augmentos-console.pages.dev |
| Branch Preview URL: | https://cloud-064-bstack-cli.dev-augmentos-console.pages.dev |
Deploying prod-augmentos-account with
|
| Latest commit: |
4b5d6fc
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://679d2751.augmentos-e84.pages.dev |
| Branch Preview URL: | https://cloud-064-bstack-cli.augmentos-e84.pages.dev |
… flatten transforms, phased rollout
…vel fields, filter to cloud containers only
…meric→string, nest metadata in _meta
…ry, eliminates heap growth
…ken throw, region source routing, duration normalization
No description provided.