bootspring monitor

Production monitoring, hooks, and alerting for deployed applications.

Overview#

The monitor command helps set up and manage production monitoring with integrations for popular monitoring and alerting services.

Usage#

bootspring monitor <command> [options]

Commands#

CommandDescription
initInitialize monitoring configuration
statusShow monitoring status
metricsCollect current metrics
providersList available providers
post-deployRun post-deploy hooks
add-monitoring <id>Add monitoring provider
add-alert <id>Add alert provider
remove-monitoring <id>Remove monitoring provider
remove-alert <id>Remove alert provider
threshold <name> <value>Set alert threshold

Monitoring Providers#

ProviderDescription
sentryError tracking and performance
datadogInfrastructure and APM
newrelicApplication performance
logrocketSession replay
axiomLog management

Alert Providers#

ProviderDescription
slackSlack notifications
discordDiscord notifications
pagerdutyOn-call alerting
emailEmail notifications

Examples#

1# Initialize monitoring 2bootspring monitor init 3 4# Check status 5bootspring monitor status 6 7# List available providers 8bootspring monitor providers 9 10# Add Sentry for error tracking 11bootspring monitor add-monitoring sentry 12 13# Add Slack for alerts 14bootspring monitor add-alert slack 15 16# Set error rate threshold 17bootspring monitor threshold error-rate 0.01 18 19# Run post-deploy hooks 20bootspring monitor post-deploy 21 22# Collect current metrics 23bootspring monitor metrics

Configuration#

Monitoring configuration is stored in .bootspring/monitor/config.json:

1{ 2 "monitoring": ["sentry", "datadog"], 3 "alerts": ["slack"], 4 "thresholds": { 5 "error-rate": 0.01, 6 "response-time-p95": 500, 7 "memory-usage": 0.8 8 }, 9 "hooks": { 10 "post-deploy": ["health-check", "notify"] 11 } 12}

Alert Thresholds#

ThresholdDefaultDescription
error-rate0.01Error rate threshold (1%)
response-time-p95500P95 response time (ms)
memory-usage0.8Memory usage threshold (80%)
cpu-usage0.7CPU usage threshold (70%)

Post-Deploy Hooks#

Hooks that run after deployment:

  1. Health Check - Verify deployment is healthy
  2. Smoke Tests - Run critical path tests
  3. Notify - Send deployment notification
  4. Metrics - Collect baseline metrics