Files
smom-dbis-138/runbooks/oracle-operations.md
defiQUG 1fb7266469 Add Oracle Aggregator and CCIP Integration
- Introduced Aggregator.sol for Chainlink-compatible oracle functionality, including round-based updates and access control.
- Added OracleWithCCIP.sol to extend Aggregator with CCIP cross-chain messaging capabilities.
- Created .gitmodules to include OpenZeppelin contracts as a submodule.
- Developed a comprehensive deployment guide in NEXT_STEPS_COMPLETE_GUIDE.md for Phase 2 and smart contract deployment.
- Implemented Vite configuration for the orchestration portal, supporting both Vue and React frameworks.
- Added server-side logic for the Multi-Cloud Orchestration Portal, including API endpoints for environment management and monitoring.
- Created scripts for resource import and usage validation across non-US regions.
- Added tests for CCIP error handling and integration to ensure robust functionality.
- Included various new files and directories for the orchestration portal and deployment scripts.
2025-12-12 14:57:48 -08:00

2.9 KiB

Oracle Operations Runbook

Overview

This runbook provides procedures for operating and maintaining the oracle system.

Oracle Update Procedures

Manual Oracle Update

  1. Check current oracle state:

    cast call $AGGREGATOR_ADDRESS "latestRoundData()" --rpc-url $RPC_URL
    
  2. Update oracle:

    cast send $AGGREGATOR_ADDRESS "updateAnswer(uint256)" $PRICE \
      --rpc-url $RPC_URL \
      --private-key $PRIVATE_KEY
    
  3. Verify update:

    cast call $AGGREGATOR_ADDRESS "latestAnswer()" --rpc-url $RPC_URL
    

Automated Oracle Updates

Oracle updates are automated via the oracle publisher service:

# Check oracle publisher status
kubectl get pods -n besu-network -l app=oracle-publisher

# View logs
kubectl logs -n besu-network -l app=oracle-publisher --tail=100

# Restart if needed
kubectl rollout restart deployment/oracle-publisher -n besu-network

Oracle Troubleshooting

Oracle Not Updating

  1. Check transmitter status:

    cast call $AGGREGATOR_ADDRESS "isTransmitter(address)" $TRANSMITTER_ADDRESS --rpc-url $RPC_URL
    
  2. Check oracle publisher:

    kubectl logs -n besu-network -l app=oracle-publisher
    
  3. Check heartbeat:

    cast call $AGGREGATOR_ADDRESS "heartbeat()" --rpc-url $RPC_URL
    

Oracle Price Deviation

  1. Check deviation threshold:

    cast call $AGGREGATOR_ADDRESS "deviationThreshold()" --rpc-url $RPC_URL
    
  2. Review price sources:

    • Check data source health
    • Verify aggregation logic
    • Review recent updates

Oracle Recovery Procedures

Recover from Stale Oracle

  1. Identify stale oracle:

    cast call $AGGREGATOR_ADDRESS "latestRoundData()" --rpc-url $RPC_URL
    
  2. Force update:

    cast send $AGGREGATOR_ADDRESS "updateAnswer(uint256)" $PRICE \
      --rpc-url $RPC_URL \
      --private-key $PRIVATE_KEY
    

Recover from Failed Transmitter

  1. Remove failed transmitter:

    cast send $AGGREGATOR_ADDRESS "removeTransmitter(address)" $TRANSMITTER \
      --rpc-url $RPC_URL \
      --private-key $ADMIN_KEY
    
  2. Add new transmitter:

    cast send $AGGREGATOR_ADDRESS "addTransmitter(address)" $NEW_TRANSMITTER \
      --rpc-url $RPC_URL \
      --private-key $ADMIN_KEY
    

Monitoring

Key Metrics

  • Oracle update frequency
  • Price deviation
  • Transmitter availability
  • Update success rate

Alerts

  • Oracle update stale (> 5 minutes)
  • Price deviation > 5%
  • Transmitter unavailable
  • Update failures

Best Practices

  1. Regular Monitoring: Check oracle status daily
  2. Backup Transmitters: Maintain multiple transmitters
  3. Price Source Diversity: Use multiple data sources
  4. Automated Updates: Rely on oracle publisher service
  5. Incident Response: Follow incident response procedures