Twin Documentation
  • Overview
  • Consumer
  • Developer
  • Operations
Dashboard Guide
Deploy
MonitoringContracts & AddressesTroubleshooting
powered by Zudoku
Operations

Monitoring

Cron Jobs as Health Indicator

The cron jobs table in the dashboard is the primary health indicator for the system. If cron jobs are running on schedule and showing no errors, the system is healthy. Key crons to watch:

Cron JobHealthy IntervalAlert If Stale By
ORACLE_PRICE_UPDATE5 min15 min
MINTING_TX_SYNC2 min10 min
CIRCULATION_SNAPSHOT24 hours48 hours
UNISWAP_AUTO_REBALANCE10 min30 min

Common Cron Errors

ErrorCron JobCauseResolution
timeout of 30000ms exceededORACLE_PRICE_UPDATEBelo API slow or downWait and retry; check Belo status
timeout of 20000ms exceededORACLE_PRICE_UPDATERPC node slowCheck RPC provider status
TRANSFER_FROM_FAILEDUNISWAP_AUTO_REBALANCEInsufficient token balance for mintCheck wallet balances; adjust maxBudget
Calculated liquidity is zeroUNISWAP_AUTO_REBALANCEPosition entirely out of rangeAdjust price band or trigger %
BitGo API errorMINTING_TX_SYNCBitGo Express unreachableCheck BitGo Express container
nonce too lowAny TX-sending cronConcurrent TX conflictUsually self-resolves; check pending TXs

Logs

Logs are sent to AWS CloudWatch via ECS container stdout/stderr.

Log Groups

  • /ecs/twin-backend-production -- Production backend logs
  • /ecs/twin-backend-staging -- Staging backend logs

Useful Log Patterns

Code
# Find oracle update errors "ORACLE_PRICE_UPDATE" AND "error" # Find BitGo transaction failures "BitGo" AND ("error" OR "failed") # Find rebalance operations "rebalance" AND ("started" OR "completed" OR "error") # Find migration output "migration" AND ("running" OR "completed" OR "error") # Find cron job executions "cron" AND "executing"

Health Check Endpoints

EndpointMethodDescriptionExpected Response
/healthGETBasic health check200 OK
/api/healthGETAPI health with DB connectivity200 OK + JSON

Key Metrics

MetricWhere to CheckHealthy Value
Oracle price freshnessDashboard > Uniswap Pools cardsUpdated < 10 min ago
Pool vs Oracle price deviationDashboard > Uniswap Pools cards< 2%
Pending minting TXsDashboard > Minteo TX history0 (or resolving)
Cron job errorsDashboard > Cron JobsNone
ECS task countAWS Console > ECSDesired = Running
CloudFront error rateAWS Console > CloudFront< 1%
Last modified on May 12, 2026
Migrations ChecklistContracts & Addresses
On this page
  • Cron Jobs as Health Indicator
  • Common Cron Errors
  • Logs
    • Log Groups
    • Useful Log Patterns
  • Health Check Endpoints
  • Key Metrics