Skip to main content

Credible Layer Runtime (Sidecar)

Home · Generic Index · Chain Overlays

This document maps the runtime enforcement architecture implemented in credible-sdk/crates/sidecar and credible-sdk/crates/assertion-executor.

Sidecar Architecture

Key code paths:

  • Sidecar bootstrap: credible-sdk/crates/sidecar/src/main.rs
  • Transport layer: credible-sdk/crates/sidecar/src/transport/
  • Core engine + queue: credible-sdk/crates/sidecar/src/engine/
  • Assertion executor + PhEVM: credible-sdk/crates/assertion-executor/
  • Assertion indexer: credible-sdk/crates/sidecar/src/indexer.rs
  • Transaction observer: credible-sdk/crates/sidecar/src/transaction_observer/

Sidecar Event Flow (Driver -> Sidecar)

Notes:

  • HTTP transport uses JSON-RPC methods (sendEvents, sendTransactions, getTransaction, getTransactions, reorg).
  • gRPC transport uses StreamEvents (bidirectional) and SubscribeResults (server push).
  • TxExecutionId ties transactions to (block_number, iteration_id, tx_hash, index).
  • The HTTP transport exposes a JSON-RPC endpoint and a health endpoint on the same server.

Assertion Indexing

The indexer maintains a local assertion store by monitoring State Oracle events and fetching assertion bytecode from Assertion DA. The assertion store is owned by the assertion executor and shared with the sidecar engine for validation.

Incident Reporting

The observer persists incidents locally and retries delivery to the dApp API until acknowledged.

Next: integration details in docs/generic/besu-integration.md and docs/chains/op-stack/overview.md.