dingo

package module
v0.68.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 28, 2026 License: Apache-2.0 Imports: 64 Imported by: 0

README

Dingo

Dingo Logo
GitHub Go Report Card Go Reference Discord

⚠️ WARNING: Dingo is under heavy active development and is not yet ready for production use. It should only be used on testnets (preview, preprod) and devnets. Do not use Dingo on mainnet with real funds.

A high-performance Cardano blockchain node implementation in Go by Blink Labs. Dingo provides:

  • Full chain synchronization and validation via Ouroboros consensus protocol
  • UTxO tracking with 41 UTXO validation rules and Plutus V1/V2/V3 smart contract execution
  • Block production with VRF leader election and stake snapshots
  • Multi-peer chain selection with density comparison and VRF tie-breaking
  • Client connectivity for wallets and applications
  • Pluggable storage backends (Badger, SQLite, PostgreSQL, MySQL, GCS, S3)
  • Tiered storage modes ("core" for consensus, "api" for full indexing)
  • Peer governance with dynamic peer selection, ledger peers, and topology support
  • Chain rollback support for handling forks with automatic state restoration
  • Fast bootstrapping via built-in Mithril client
  • Multiple external interfaces: general-purpose APIs (UTxO RPC, Blockfrost-compatible REST, Mesh/Rosetta) plus Bark for Dingo-to-Dingo C2 and archive services

Note: On Windows systems, named pipes are used instead of Unix sockets for node-to-client communication.

dingo screenshot

Running

Dingo supports configuration via a YAML config file (dingo.yaml), environment variables, and command-line flags. Priority: CLI flags > environment variables > YAML config > defaults.

A sample configuration file is provided at dingo.yaml.example. You can copy and edit this file to configure Dingo for your local or production environment.

Environment Variables

The following environment variables modify Dingo's behavior:

  • CARDANO_BIND_ADDR
    • IP address to bind for listening (default: 0.0.0.0)
  • CARDANO_CONFIG
    • Full path to the Cardano node configuration (default: ./config/cardano/preview/config.json)
    • Use your own configuration files for different networks
    • Genesis configuration files are read from the same directory by default
  • CARDANO_DATABASE_PATH
    • A directory which contains the ledger database files (default: .dingo)
    • This is the location for persistent data storage for the ledger
  • CARDANO_INTERSECT_TIP
    • Ignore prior chain history and start from current position (default: false)
    • This is experimental and will likely break... use with caution
  • CARDANO_METRICS_PORT
    • TCP port to bind for listening for Prometheus metrics (default: 12798)
  • CARDANO_NETWORK
    • Named Cardano network (default: preview)
  • CARDANO_PRIVATE_BIND_ADDR
    • IP address to bind for listening for Ouroboros NtC (default: 127.0.0.1)
  • CARDANO_PRIVATE_PORT
    • TCP port to bind for listening for Ouroboros NtC (default: 3002)
  • CARDANO_RELAY_PORT
    • TCP port to bind for listening for Ouroboros NtN (default: 3001)
  • CARDANO_SOCKET_PATH
    • UNIX socket path for listening (default: dingo.socket)
    • This socket speaks Ouroboros NtC and is used by client software
  • CARDANO_TOPOLOGY
    • Full path to the Cardano node topology (default: "")
  • DINGO_PLUGINS_API_UTXORPC_CONFIG_PORT
    • TCP port to bind for listening for UTxO RPC (default: 9090)
    • Compatibility alias: DINGO_UTXORPC_PORT
  • DINGO_PLUGINS_API_BLOCKFROST_CONFIG_PORT
    • TCP port for the Blockfrost-compatible REST API (default: 3000)
    • Compatibility alias: DINGO_BLOCKFROST_PORT
  • DINGO_PLUGINS_API_MESH_CONFIG_PORT
    • TCP port for the Mesh (Coinbase Rosetta) API (default: 8080)
    • Compatibility alias: DINGO_MESH_PORT
  • DINGO_BARK_PORT
    • TCP port for the Bark block archive API (default: 0, disabled)
  • DINGO_BARK_BASE_URL
    • Base URL of a remote Bark archive node used for archive fallback (default: empty, disabled)
  • DINGO_BARK_BLOCK_DOWNLOAD_HOSTS
    • Comma-separated HTTPS hostnames additionally allowed for Bark-supplied block download URLs. The allowlist always includes the DINGO_BARK_BASE_URL hostname.
  • DINGO_HISTORY_EXPIRY_ENABLED
    • Enable local expiry of immutable block CBOR older than the ledger stability window (default: false)
  • DINGO_HISTORY_EXPIRY_FREQUENCY
    • How often a history-expiry node scans for old local blocks (default: 1h)
  • DINGO_STORAGE_MODE
    • Storage mode: core (default) or api
    • core stores only consensus data (UTxOs, certs, pools, protocol params)
    • api additionally stores witnesses, scripts, datums, redeemers, and tx metadata
    • API servers (Blockfrost, UTxO RPC, Mesh) require api mode
  • DINGO_RUN_MODE
    • Run mode: serve (full node, default), load (batch import), dev (development mode), or leios (experimental Leios/Dijkstra protocol support)
  • DINGO_START_ERA
    • Experimental startup era override. Set to dijkstra only for Dijkstra/Leios test networks; leave empty to follow genesis protocol version.
  • DINGO_LOGGING_FORMAT
    • Log output format: text (default, human-readable) or json (machine-parseable, for ELK/Loki ingestion)
  • DINGO_LOGGING_LEVEL
    • Minimum log level: debug, info (default), warn, or error (the --debug flag overrides this to debug)
  • TLS_CERT_FILE_PATH - SSL certificate to use, requires TLS_KEY_FILE_PATH (default: empty)
  • TLS_KEY_FILE_PATH - SSL certificate key to use (default: empty)
Block Production (SPO Mode)

To run Dingo as a stake pool operator producing blocks:

  • CARDANO_BLOCK_PRODUCER - Enable block production (default: false)
  • CARDANO_SHELLEY_VRF_KEY - Path to VRF signing key file
  • CARDANO_SHELLEY_KES_KEY - Path to KES signing key file
  • CARDANO_SHELLEY_OPERATIONAL_CERTIFICATE - Path to operational certificate file
Quick Start
# Preview network (default)
./dingo

# Mainnet
CARDANO_NETWORK=mainnet ./dingo

# Or with explicit config path
CARDANO_NETWORK=mainnet CARDANO_CONFIG=path/to/mainnet/config.json ./dingo

Dingo creates a dingo.socket file that speaks Ouroboros node-to-client and is compatible with cardano-cli, adder, kupo, and other Cardano client tools.

Cardano configuration files are bundled in the Docker image. For local builds, you can find them at docker-cardano-configs.

Docker

# Run on preview (default)
docker run -p 3001:3001 ghcr.io/blinklabs-io/dingo

# Run on mainnet with persistent storage
docker run -p 3001:3001 \
  -e CARDANO_NETWORK=mainnet \
  -v dingo-data:/data/db \
  -v dingo-ipc:/ipc \
  ghcr.io/blinklabs-io/dingo

The image is based on Debian bookworm-slim and includes cardano-cli, nview, and txtop. Mithril snapshot support is built into dingo natively (dingo mithril sync). The Dockerfile sets CARDANO_DATABASE_PATH=/data/db and CARDANO_SOCKET_PATH=/ipc/dingo.socket, overriding the local defaults of .dingo and dingo.socket — the volume mounts above map to these container paths.

Port Service Default
3001 Ouroboros NtN (node-to-node) Enabled
3002 Ouroboros NtC over TCP Enabled
12798 Prometheus metrics Enabled
3000 Blockfrost REST API Disabled
8080 Mesh (Rosetta) REST API Disabled
9090 UTxO RPC (gRPC) Disabled
Bark archive (gRPC) Disabled (example when enabled: 9091)

Storage Modes

Dingo has two storage modes that control how much data is persisted:

Mode What's Stored Use Case
core (default) UTxOs, certificates, pools, protocol parameters Relays, block producers
api Core data + witnesses, scripts, datums, redeemers, tx metadata Nodes serving API queries
# Relay or block producer (default)
./dingo

# API node
DINGO_STORAGE_MODE=api ./dingo

Or in dingo.yaml:

storageMode: "api"

API Servers and Bark

Dingo includes three general-purpose external APIs plus Bark. UTxO RPC, Blockfrost, and Mesh are client-facing APIs and require storageMode: "api". Bark is different: it is Dingo's own protocol for Dingo-to-Dingo C2/archive services, not a general-purpose application API. Set an individual port to 0 to disable a specific interface. The Blockfrost server currently exposes the latest, epoch, network, and pool subset.

The shorter DINGO_UTXORPC_PORT, DINGO_BLOCKFROST_PORT, and DINGO_MESH_PORT names remain supported for compatibility. If both a compatibility name and its plugin-form name are set, the plugin-form value takes precedence.

Interface Port Env Var Default Protocol Role
UTxO RPC DINGO_PLUGINS_API_UTXORPC_CONFIG_PORT 9090 gRPC General-purpose client API
Blockfrost DINGO_PLUGINS_API_BLOCKFROST_CONFIG_PORT 3000 REST General-purpose client API
Mesh (Rosetta) DINGO_PLUGINS_API_MESH_CONFIG_PORT 8080 REST General-purpose client API
Bark DINGO_BARK_PORT disabled Connect/gRPC Dingo-to-Dingo C2/archive protocol
# Enable Blockfrost API on port 3100 and UTxO RPC on port 9090
DINGO_STORAGE_MODE=api \
  DINGO_PLUGINS_API_BLOCKFROST_CONFIG_PORT=3100 \
  DINGO_PLUGINS_API_UTXORPC_CONFIG_PORT=9090 \
  ./dingo

Or in dingo.yaml:

storageMode: "api"
plugins:
  api:
    blockfrost: {provider: builtin, config: {port: 3100}}
    utxorpc: {provider: builtin, config: {port: 9090}}
Archive And History Expiry Nodes

Dingo can expire immutable block CBOR from a local blob store once blocks are older than the ledger-derived stability window. This History Expiry mode is a valid standalone operational mode: without an archive fallback, reads for expired blocks return a clear history-expired error. When paired with Bark, expired or missing historical block reads can be transparently served from a remote archive node.

An archive node uses a signed-URL-capable blob plugin (s3 or gcs) and enables Bark with barkPort. Bark answers Dingo-to-Dingo archive requests by returning a signed object-storage URL plus block metadata. Badger is valid for a normal local blob store, but it does not provide signed URLs and should not be used as the Bark archive backend.

For local source builds, the s3 and gcs blob plugins require -tags dingo_extra_plugins or make build. Official release binaries include the extra plugin tag.

storageMode: "core"
plugins:
  storage:
    blob:
      provider: s3
      config:
        bucket: "dingo-archive"
        region: "us-east-1"
        prefix: "preview"
barkPort: 9091

A history-expiry node keeps its normal local blob store and enables historyExpiry. Dingo expires blocks older than the ledger-derived stability window while keeping local indexes and metadata, so reads fail explicitly as expired history unless an archive wrapper can serve them.

storageMode: "core"
plugins:
  storage:
    blob:
      provider: badger
      config: {}
historyExpiry:
  enabled: true
  frequency: 1h

Add barkBaseUrl when expired historical reads should fall back to a Bark archive:

barkBaseUrl: "http://archive.example.internal:9091"
barkBlockDownloadHosts:
  - "dingo-archive.s3.us-east-1.amazonaws.com"

Bark archive RPC may use the configured barkBaseUrl, but the block download URLs returned by that service must be HTTPS, must not contain credentials, and must match either the barkBaseUrl hostname or barkBlockDownloadHosts.

The runnable demonstration in internal/test/archive-demo/ brings up an S3 compatible Minio archive node, a local Badger history-expiry node, and an end-to-end BlockFetch check through Bark.

Deployment Patterns

Relay node (consensus only, no APIs):

./dingo

API / data node (full indexing, one or more APIs):

DINGO_STORAGE_MODE=api DINGO_PLUGINS_API_BLOCKFROST_CONFIG_PORT=3100 ./dingo

Archive node (cloud object storage plus Bark archive service):

DINGO_PLUGINS_STORAGE_BLOB_PROVIDER=s3 DINGO_BARK_PORT=9091 ./dingo

History-expiry node (local storage plus a remote Bark archive):

DINGO_HISTORY_EXPIRY_ENABLED=true \
DINGO_BARK_BASE_URL=http://archive.example.internal:9091 ./dingo

Block producer (consensus only, with SPO keys):

CARDANO_BLOCK_PRODUCER=true \
  CARDANO_SHELLEY_VRF_KEY=/keys/vrf.skey \
  CARDANO_SHELLEY_KES_KEY=/keys/kes.skey \
  CARDANO_SHELLEY_OPERATIONAL_CERTIFICATE=/keys/opcert.cert \
  ./dingo

When storageMode=core, the Badger blob store defaults to mmap-only settings: block-cache-size=0, index-cache-size=0, and compression=false. When storageMode=api, the default Badger profile is block-cache-size=268435456, index-cache-size=0, and compression=true. The plugins.storage.blob.config Badger settings (YAML or the matching DINGO_PLUGINS_STORAGE_BLOB_CONFIG_* environment variables) override those defaults only when explicitly set.

See dingo.yaml.example for the full set of configuration options.

Fast Bootstrapping with Mithril

Instead of syncing from genesis (which can take days on mainnet), you can bootstrap Dingo using a Mithril snapshot. Dingo has a built-in Mithril client that handles download, extraction, and import automatically. This is the fastest way to get a node running.

# Bootstrap from Mithril and start syncing
./dingo -n preview sync --mithril

# Then start the node
./dingo -n preview serve

Or use the subcommand form for more control:

# List available snapshots
./dingo -n preview mithril list

# Show snapshot details
./dingo -n preview mithril show <hash>

# Download and import
./dingo -n preview mithril sync

Two Mithril artifact backends are supported via mithril.backend (or --mithril-backend): v2 (default) restores from incremental per-immutable-file archives verified against the certified merkle root, while v1 uses the legacy full snapshot tarballs, which upstream Mithril is phasing out. The mithril list and mithril show subcommands follow the configured backend.

This imports:

  • All blocks from genesis (stored in blob store for serving peers)
  • Current UTxO set, stake accounts, pool registrations, DRep registrations
  • Stake snapshots (mark/set/go) for leader election
  • Protocol parameters, governance state, treasury/reserves
  • Complete epoch history for slot-to-time calculations

Individual transaction records, certificate history, witness/script/datum storage, and governance vote records for blocks before the snapshot are not stored by the snapshot itself. In core mode these are not needed — consensus, block production, and serving blocks to peers work without them, and new blocks processed after bootstrap will have full metadata. In api mode, dingo mithril sync automatically runs a backfill step after loading the snapshot to populate this historical data, so API servers (Blockfrost, UTxO RPC, Mesh) have complete records from genesis.

Performance (preview network, ~4M blocks):

Phase core mode api mode
Download snapshot (~2.6 GB) ~1-2 min ~1-2 min
Extract + download ancillary ~1 min ~1 min
Import ledger state (UTxOs, accounts, pools, DReps, epochs) ~12 min ~12 min
Load blocks into blob store ~36 min ~36 min
Backfill historical metadata ~varies
Total ~50 min ~50 min + backfill
Disk Space Requirements

Bootstrapping requires temporary disk space for both the downloaded snapshot and the Dingo database:

Network Snapshot Size Dingo DB Total Needed
mainnet ~180 GB ~200+ GB ~400 GB
preprod ~60 GB ~80 GB ~150 GB
preview ~15 GB ~25 GB ~50 GB

These are approximate values that grow over time. The snapshot can be deleted after import, but you need sufficient space for both during the load process.

Database Plugins

Dingo supports pluggable storage backends for both blob storage (blocks, transactions) and metadata storage. This allows you to choose the best storage solution for your use case.

Available Plugins

For local source builds, badger, sqlite, the default mempool, and all three built-in API providers are always available. GCS, S3, PostgreSQL, and MySQL require -tags dingo_extra_plugins or an official release binary.

Blob Storage Plugins:

  • badger - BadgerDB local key-value store (default)
  • gcs - Google Cloud Storage blob store
  • s3 - AWS S3 blob store

Metadata Storage Plugins:

  • sqlite - SQLite relational database (default)
  • postgres - PostgreSQL relational database
  • mysql - MySQL relational database
Plugin Selection

Plugins can be selected via command-line flags, environment variables, or configuration file:

# Command line
./dingo --blob gcs --metadata sqlite

# Environment variables
DINGO_PLUGINS_STORAGE_BLOB_PROVIDER=gcs
DINGO_PLUGINS_STORAGE_METADATA_PROVIDER=sqlite

# Configuration file (dingo.yaml)
plugins:
  storage:
    blob:
      provider: gcs
      config:
        bucket: my-cardano-blocks
    metadata:
      provider: sqlite
      config: {}
Plugin Configuration

Each capability has exactly one selected provider. Provider configuration is strictly decoded; unknown fields fail startup. Generic environment variables flatten the capability and config path, for example DINGO_PLUGINS_MEMPOOL_CONFIG_CAPACITY and DINGO_PLUGINS_API_UTXORPC_CONFIG_PORT. See dingo.yaml.example.

CARDANO_DATABASE_PATH (or databasePath / --data-dir) remains a shortcut that supplies the data directory to both local storage providers. Set dataDir on either local provider when blob and metadata storage need separate paths; the provider value overrides the shared shortcut.

BadgerDB Options:

  • dataDir - Badger data directory (defaults to the shared database path)
  • blockCacheSize - Block cache size in bytes
  • indexCacheSize - Index cache size in bytes
  • compression - Enable ZSTD compression
  • gc - Enable garbage collection

Leave mode-sensitive Badger settings unset to use storage-mode defaults.

Google Cloud Storage Options:

  • bucket - GCS bucket name

AWS S3 Options:

  • endpoint - Optional custom S3-compatible endpoint
  • bucket - S3 bucket name
  • region - AWS region
  • prefix - Path prefix within bucket
  • timeout - Request timeout

S3 credentials use the standard AWS credential chain.

SQLite Options:

  • dataDir - SQLite data directory (defaults to the shared database path)
  • maxConnections - Maximum connection count

PostgreSQL Options:

  • host - PostgreSQL server hostname
  • port - PostgreSQL server port
  • user - Database user
  • password - Database password
  • database - Database name
  • sslMode - PostgreSQL SSL mode
  • timeZone - PostgreSQL time zone (default: UTC)
  • dsn - Full PostgreSQL DSN (overrides the individual connection fields)

MySQL Options:

  • host - MySQL server hostname
  • port - MySQL server port
  • user - Database user
  • password - Database password
  • database - Database name
  • sslMode - MySQL TLS mode (mapped to tls in the DSN)
  • timeZone - MySQL time zone location (default: UTC)
  • dsn - Full MySQL DSN (overrides other options when set)
Migrating From Pre-Plugin Configuration

The plugin platform replaces the earlier per-plugin CLI flags and environment variables for storage, mempool, and API ports with the plugins.* config tree (YAML), the generic DINGO_PLUGINS_* environment scheme, and the provider selector flags. Every removed setting has an equivalent below; values are unchanged, only where they are set has moved.

Removed setting New equivalent
--mempool-capacity, CARDANO_MEMPOOL_CAPACITY plugins.mempool.config.capacity / DINGO_PLUGINS_MEMPOOL_CONFIG_CAPACITY
--eviction-watermark, DINGO_MEMPOOL_EVICTION_WATERMARK plugins.mempool.config.evictionWatermark / DINGO_PLUGINS_MEMPOOL_CONFIG_EVICTION_WATERMARK
--rejection-watermark, DINGO_MEMPOOL_REJECTION_WATERMARK plugins.mempool.config.rejectionWatermark / DINGO_PLUGINS_MEMPOOL_CONFIG_REJECTION_WATERMARK
DINGO_DATABASE_BLOB_PLUGIN --blob, plugins.storage.blob.provider, or DINGO_PLUGINS_STORAGE_BLOB_PROVIDER
DINGO_DATABASE_METADATA_PLUGIN --metadata, plugins.storage.metadata.provider, or DINGO_PLUGINS_STORAGE_METADATA_PROVIDER
--blob-badger-*, DINGO_DATABASE_BLOB_BADGER_* plugins.storage.blob.config.* / DINGO_PLUGINS_STORAGE_BLOB_CONFIG_*
--metadata-sqlite-*, DINGO_DATABASE_METADATA_SQLITE_* plugins.storage.metadata.config.* / DINGO_PLUGINS_STORAGE_METADATA_CONFIG_*
MYSQL_* MySQL connection aliases (-tags dingo_extra_plugins) plugins.storage.metadata.config.* / DINGO_PLUGINS_STORAGE_METADATA_CONFIG_*
--utxorpc-port, --blockfrost-port, --mesh-port plugins.api.<name>.config.port / DINGO_PLUGINS_API_<NAME>_CONFIG_PORT

Provider config fields use lowerCamelCase in YAML; the environment form uppercases them with underscore separators (dataDir becomes ..._CONFIG_DATA_DIR). The pre-plugin API port variables DINGO_UTXORPC_PORT, DINGO_BLOCKFROST_PORT, and DINGO_MESH_PORT still work as compatibility aliases, and setting an API port to 0 disables that server.

Listing Available Plugins

You can see all available plugins and their descriptions:

./dingo list

Plugin Development

For information on developing custom storage plugins, see PLUGIN_DEVELOPMENT.md.

Features

  • Network
    • UTxO RPC
    • Ouroboros
      • Node-to-node
        • ChainSync
        • BlockFetch
        • TxSubmission2
      • Node-to-client
        • ChainSync
        • LocalTxMonitor
        • LocalTxSubmission
        • LocalStateQuery
      • Peer governor
        • Topology config
        • Peer churn (full PeerChurnEvent with gossip/public root churn, bootstrap events)
        • Ledger peers
        • Peer sharing
        • Denied peers tracking
      • Connection manager
        • Inbound connections
          • Node-to-client over TCP
          • Node-to-client over UNIX socket
          • Node-to-node over TCP
        • Outbound connections
          • Node-to-node over TCP
  • Ledger
    • Blocks
      • Block storage
      • Chain selection (density comparison, VRF tie-breaker, ChainForkEvent)
    • UTxO tracking
    • Protocol parameters
    • Genesis validation
    • Block header validation (VRF/KES/OpCert cryptographic verification)
    • Certificates
      • Pool registration
      • Stake registration/delegation
      • Account registration checks
      • DRep registration
      • Governance
    • Transaction validation
      • Phase 1 validation
        • UTxO rules
        • Fee validation (full fee calculation with script costs)
        • Transaction size and ExUnit budget validation
        • Witnesses
        • Block body
        • Certificates
        • Delegation/pools
        • Governance
      • Phase 2 validation
        • Plutus V1 smart contract execution
        • Plutus V2 smart contract execution
        • Plutus V3 smart contract execution
  • Block production
    • VRF leader election with stake snapshots
    • Block forging with KES/OpCert signing
    • Slot battle detection
  • Mempool
    • Accept transactions from local clients
    • Distribute transactions to other nodes
    • Validation of transaction on add
    • Consumer tracking
    • Transaction purging on chain update
    • Watermark-based eviction and rejection
  • Database Recovery
    • Chain rollback support (SQLite, PostgreSQL, and MySQL plugins)
    • State restoration on rollback
    • WAL mode for crash recovery
    • Automatic rollback on transaction error
  • Stake Snapshots
    • Mark/Set/Go rotation at epoch boundaries
    • Genesis snapshot capture
  • API Servers
    • UTxO RPC (gRPC)
    • WIP Blockfrost-compatible REST API
    • Mesh (Coinbase Rosetta) API
  • Mithril Bootstrap
    • Built-in Mithril client
    • Ledger state import (UTxOs, accounts, pools, DReps, epochs)
    • Block loading from ImmutableDB

Additional planned features can be found in our issue tracker and project boards.

Catalyst Fund 12 - Go Node (Dingo)
Catalyst Fund 13 - Archive Node

Check the issue tracker for known issues. Due to rapid development, bugs happen especially as there is functionality which has not yet been developed.

Development / Building

This requires Go 1.25 or later. You also need make.

# Format, test, and build (default target)
make

# Build only
make build

# Run
./dingo

# Run without building a binary
go run ./cmd/dingo/
Testing
make test                                    # All tests with race detection
go test -v -race -run TestName ./package/    # Single test
make bench                                   # Benchmarks
Profiling
# Load testdata with CPU and memory profiling
make test-load-profile

# Analyze
go tool pprof cpu.prof
go tool pprof mem.prof

DevNet

The DevNet runs a private Cardano network with Dingo and cardano-node producing blocks side by side. It validates that Dingo forges blocks, maintains consensus, and interoperates with the reference node.

Architecture

The DevNet uses Docker Compose to run three Cardano nodes plus a load generator on a bridge network:

Container Role Host Port
dingo-producer Dingo block producer (pool 1) 3010
cardano-producer cardano-node block producer (pool 2) 3011
cardano-relay Relay node (no block production) 3012
txpump Submits payment transactions into Dingo's mempool

A configurator init container generates fresh pool keys and genesis files before nodes start. The txpump sidecar comes up after Dingo is healthy and continuously feeds the mempool so block bodies and tx-submission paths are exercised alongside consensus.

Prerequisites
  • Docker with the Compose plugin (docker compose)
  • Go 1.25+
Running the Automated Tests

The test suite builds the Dingo Docker image, starts all containers, waits for health checks, and runs Go integration tests tagged with //go:build devnet:

cd internal/test/devnet/

# Run all devnet tests
./run-tests.sh

# Run a specific test
./run-tests.sh -run TestBasicBlockForging

# Keep containers running after tests pass (for inspection)
./run-tests.sh --keep-up

Override host ports if needed:

DEVNET_DINGO_PORT=4010 DEVNET_CARDANO_PORT=4011 DEVNET_RELAY_PORT=4012 ./run-tests.sh
Running the DevNet Manually

For longer-running manual tests (soak testing, observing behavior over multiple epochs, debugging):

cd internal/test/devnet/

# Start all containers
./start.sh

# Watch logs
docker compose -f docker-compose.yml logs -f

# Watch a specific node
docker compose -f docker-compose.yml logs -f dingo-producer

# Stop and clean up
./stop.sh

Containers remain running until you stop them. The DevNet parameters (in testnet.yaml) use 1-second slots and 500-slot epochs (~8 minutes per epoch) with activeSlotsCoeff=0.4 and securityParam (k)=40, so you can observe epoch transitions, leader election, and stake snapshot rotation relatively quickly.

See internal/test/devnet/README.md for full details on the harness, configurator, available test scenarios, and port/address overrides.

Local DevNet (Without Docker)

For quick iteration without Docker, devmode.sh runs Dingo directly against a local devnet genesis. It resets state and updates genesis timestamps on each run:

# Run in devnet mode
./devmode.sh

# With debug logging
DEBUG=true ./devmode.sh

This stores state in .devnet/ and uses genesis configs from config/cardano/devnet/. It runs a single Dingo node (no cardano-node counterpart), which is useful for testing startup, epoch transitions, and block production in isolation.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	DatabaseWorkerPoolConfig ledger.DatabaseWorkerPoolConfig
	// contains filtered or unexported fields
}

func NewConfig

func NewConfig(opts ...ConfigOptionFunc) Config

NewConfig creates a new dingo config with the specified options

type ConfigOptionFunc

type ConfigOptionFunc func(*Config)

ConfigOptionFunc is a type that represents functions that modify the Connection config

func WithActivePeersQuotas added in v0.21.0

func WithActivePeersQuotas(
	topologyQuota, gossipQuota, ledgerQuota int,
) ConfigOptionFunc

WithActivePeersQuotas specifies the per-source quotas for active peers. Use 0 to use the default quota, or a negative value to disable enforcement. Default quotas: topology=20, gossip=20, ledger=20

func WithBarkBaseUrl added in v0.22.0

func WithBarkBaseUrl(baseUrl string) ConfigOptionFunc

func WithBarkBlockDownloadHosts added in v0.61.2

func WithBarkBlockDownloadHosts(hosts []string) ConfigOptionFunc

func WithBarkPort added in v0.22.0

func WithBarkPort(port uint) ConfigOptionFunc

func WithBindAddr added in v0.22.0

func WithBindAddr(addr string) ConfigOptionFunc

WithBindAddr specifies the IP address used for API listeners (Blockfrost, Mesh, UTxO RPC). The default is "0.0.0.0" (all interfaces).

func WithBlockProducer added in v0.22.0

func WithBlockProducer(enabled bool) ConfigOptionFunc

WithBlockProducer enables block production mode (CARDANO_BLOCK_PRODUCER). When enabled, the node will attempt to produce blocks using the configured credentials.

func WithBootstrapPromotionMinDiversityGroups added in v0.37.0

func WithBootstrapPromotionMinDiversityGroups(n int) ConfigOptionFunc

WithBootstrapPromotionMinDiversityGroups sets the minimum number of bootstrap-time peer diversity groups to prefer before falling back to pure score ordering. Non-positive values use the peer-governor default.

func WithCORSAllowedOrigins added in v0.50.0

func WithCORSAllowedOrigins(origins []string) ConfigOptionFunc

WithCORSAllowedOrigins configures browser CORS access for public API servers. Use []string{"*"} to allow any origin, or an empty list to disable CORS headers.

func WithCacheConfig added in v0.29.0

func WithCacheConfig(
	blockLRU, hotUtxo, hotTx int,
	hotTxMaxBytes int64,
) ConfigOptionFunc

WithCacheConfig sets the CBOR cache sizes for block LRU, hot UTxO, and hot TX caches.

func WithCardanoNodeConfig

func WithCardanoNodeConfig(
	cardanoNodeConfig *cardano.CardanoNodeConfig,
) ConfigOptionFunc

WithCardanoNodeConfig specifies the CardanoNodeConfig object to use. This is mostly used for loading genesis config files referenced by the dingo config

func WithChainsyncHeaderStrategy added in v0.55.0

func WithChainsyncHeaderStrategy(
	strategy chainsync.HeaderSyncStrategy,
) ConfigOptionFunc

WithChainsyncHeaderStrategy selects how headers from multiple eligible chainsync peers drive ledger ingress. The default is chainsync.HeaderSyncStrategyPrimary (single active peer with failover).

func WithChainsyncMaxClients added in v0.22.0

func WithChainsyncMaxClients(
	maxClients int,
) ConfigOptionFunc

WithChainsyncMaxClients specifies the maximum number of concurrent chainsync client connections. Default is 3.

func WithChainsyncStallTimeout added in v0.22.0

func WithChainsyncStallTimeout(
	timeout time.Duration,
) ConfigOptionFunc

WithChainsyncStallTimeout specifies the duration after which a chainsync client with no activity is considered stalled. Default is 2 minutes.

func WithDatabasePath

func WithDatabasePath(dataDir string) ConfigOptionFunc

WithDatabasePath specifies the persistent data directory to use. The default is to store everything in memory

func WithDatabaseWorkerPoolConfig added in v0.20.0

func WithDatabaseWorkerPoolConfig(
	cfg ledger.DatabaseWorkerPoolConfig,
) ConfigOptionFunc

WithDatabaseWorkerPoolConfig specifies the database worker pool configuration

func WithDelegatorInactivity added in v0.67.0

func WithDelegatorInactivity(enabled bool, epochs uint64) ConfigOptionFunc

WithDelegatorInactivity configures the CIP-0163 reward-account inactivity expiry. It is consensus-affecting and disabled by default; enable it only on a network where every node also enables it. epochs is the inactivity window and is used only when enabled.

func WithForgeStaleGapThresholdSlots added in v0.22.0

func WithForgeStaleGapThresholdSlots(slots uint64) ConfigOptionFunc

WithForgeStaleGapThresholdSlots sets the slot gap threshold for stale database warnings. Use 0 to fall back to the built-in default.

func WithForgeSyncToleranceSlots added in v0.22.0

func WithForgeSyncToleranceSlots(slots uint64) ConfigOptionFunc

WithForgeSyncToleranceSlots sets the slot gap tolerated before forging is skipped. Use 0 to fall back to the built-in default.

func WithFullPotRewards added in v0.67.0

func WithFullPotRewards(enabled bool) ConfigOptionFunc

WithFullPotRewards configures CIP-0163 full-pot reward distribution. It is consensus-affecting and disabled by default; enable it only on a network where every node also enables it. When enabled, the entire epoch reward pot is distributed to eligible pools and delegators instead of returning the residual to reserves.

func WithGenesisBootstrap added in v0.37.0

func WithGenesisBootstrap(enabled bool) ConfigOptionFunc

WithGenesisBootstrap enables Genesis-mode chain selection during from-origin bootstrap. Genesis mode automatically exits once the local tip is within the configured Genesis window of the best known peer tip.

func WithGenesisCorroborationPeers added in v0.67.0

func WithGenesisCorroborationPeers(peers int) ConfigOptionFunc

WithGenesisCorroborationPeers sets the number of independent peers that must report the same recent blocks before a fast (shallow) block source may drive Genesis-mode chain selection. This is the Ouroboros Genesis trust control for biased fast-sync sources (e.g. the Genesis Sync Accelerator): an uncorroborated or divergent fast source is denied selection and stalls rather than steering the local chain.

Only a zero value disables corroboration (density-only Genesis selection). A negative value is invalid and fails closed: the chain selector clamps it to 1 (require one corroborator) rather than treating it as disabled, so a misconfiguration cannot silently switch off the security gate.

func WithGenesisWindowSlots added in v0.37.0

func WithGenesisWindowSlots(slots uint64) ConfigOptionFunc

WithGenesisWindowSlots overrides the Genesis density comparison window. A zero value lets the node derive the window from Shelley genesis parameters using 3k/f.

func WithHistoryExpiry added in v0.52.0

func WithHistoryExpiry(cfg HistoryExpiryConfig) ConfigOptionFunc

WithHistoryExpiry configures local immutable block history expiry.

func WithInactivityTimeout added in v0.26.0

func WithInactivityTimeout(d time.Duration) ConfigOptionFunc

WithInactivityTimeout specifies how long a hot peer can be inactive before being demoted to warm. Non-positive values are ignored. Default: 10m.

func WithInboundPeerGovernance added in v0.37.0

func WithInboundPeerGovernance(
	warmTarget int,
	hotQuota int,
	minTenure time.Duration,
	hotScoreThreshold float64,
	pruneAfter time.Duration,
	duplexOnlyForHot bool,
	cooldown time.Duration,
) ConfigOptionFunc

WithInboundPeerGovernance specifies explicit inbound peer governance budget and phase-1 policy fields. Non-positive values use peer governor defaults.

func WithIntersectPoints

func WithIntersectPoints(points []ocommon.Point) ConfigOptionFunc

WithIntersectPoints specifies intersect point(s) for the initial chainsync. The default is to start at chain genesis

func WithIntersectTip

func WithIntersectTip(intersectTip bool) ConfigOptionFunc

WithIntersectTip specifies whether to start the initial chainsync at the current tip. The default is to start at chain genesis

func WithLedgerPeerTarget added in v0.31.0

func WithLedgerPeerTarget(n int) ConfigOptionFunc

WithLedgerPeerTarget specifies the target number of known ledger peers. Discovery will add peers only until this target is reached. Negative values disable ledger peer discovery, 0 uses defaultLedgerPeerTarget, and positive values use that target. Default: 20.

func WithLeiosPipelineTiming added in v0.54.0

func WithLeiosPipelineTiming(timing leios.PipelineTiming) ConfigOptionFunc

WithLeiosPipelineTiming overrides the provisional Leios pipeline stage timing windows. CIP-0164 has not finalized these parameters, so they are kept off-chain and overridable here rather than as protocol parameters. When unset, leios.DefaultPipelineTiming applies. Experimental, leios runMode only.

func WithLeiosVoteSigningKeyFile added in v0.53.0

func WithLeiosVoteSigningKeyFile(path string) ConfigOptionFunc

WithLeiosVoteSigningKeyFile specifies the path to a hex-encoded BLS12-381 Leios vote signing key (DINGO_LEIOS_VOTE_SIGNING_KEY_FILE). When set on a block producer whose pool is a Leios committee member, the node emits votes for endorser blocks. Experimental, leios runMode only.

func WithLeiosVoterPublicKeys added in v0.53.0

func WithLeiosVoterPublicKeys(keys map[string]string) ConfigOptionFunc

WithLeiosVoterPublicKeys specifies the static Leios voter public key registry (DINGO_LEIOS_VOTER_PUBLIC_KEYS): hex pool key hash to hex-encoded BLS12-381 public key. Stands in for CIP-0164 key registration, which is not yet specified. Experimental, leios runMode only.

func WithListeners

func WithListeners(listeners ...ListenerConfig) ConfigOptionFunc

WithListeners specifies the listener config(s) to use

func WithLogger

func WithLogger(logger *slog.Logger) ConfigOptionFunc

WithLogger specifies the logger to use. This defaults to discarding log output

func WithMaxConnectionsPerIP added in v0.26.0

func WithMaxConnectionsPerIP(n int) ConfigOptionFunc

WithMaxConnectionsPerIP specifies the maximum number of concurrent inbound connections from a single IP. Non-positive values are ignored. Default: 5.

func WithMaxInboundConns added in v0.26.0

func WithMaxInboundConns(n int) ConfigOptionFunc

WithMaxInboundConns specifies the maximum number of inbound connections. Non-positive values are ignored. Default: 100.

func WithMidnightConfig added in v0.55.0

func WithMidnightConfig(cfg MidnightConfig) ConfigOptionFunc

WithMidnightConfig configures the Midnight indexer and optional gRPC API.

func WithMinHotPeers added in v0.26.0

func WithMinHotPeers(n int) ConfigOptionFunc

WithMinHotPeers specifies the minimum number of hot peers before aggressive promotion is triggered. Non-positive values are ignored. Default: 10.

func WithMinPoolMargin added in v0.67.0

func WithMinPoolMargin(basisPoints uint) ConfigOptionFunc

WithMinPoolMargin configures the CIP-23 minimum pool margin (minimum variable fee) in basis points, [0, 10000] (150 = 1.5%). It is consensus-affecting and off by default (0), taking effect only in Dijkstra and later. Enable a nonzero value only on a network where every node also enables the same value.

func WithNetwork

func WithNetwork(network string) ConfigOptionFunc

WithNetwork specifies the named network to operate on. This will automatically set the appropriate network magic value

func WithNetworkMagic

func WithNetworkMagic(networkMagic uint32) ConfigOptionFunc

WithNetworkMagic specifies the network magic value to use. This will override any named network specified

func WithOffchainMetadataConfig added in v0.54.0

func WithOffchainMetadataConfig(cfg OffchainMetadataConfig) ConfigOptionFunc

WithOffchainMetadataConfig configures the API-mode off-chain metadata fetcher. Zero values use the fetcher's internal defaults.

func WithOutboundSourcePort

func WithOutboundSourcePort(port uint) ConfigOptionFunc

WithOutboundSourcePort specifies the source port to use for outbound connections. This defaults to dynamic source ports

func WithPeerSharing

func WithPeerSharing(peerSharing bool) ConfigOptionFunc

WithPeerSharing specifies whether to enable peer sharing. This is disabled by default

func WithPeerTargets added in v0.21.0

func WithPeerTargets(
	targetKnown, targetEstablished, targetActive int,
) ConfigOptionFunc

WithPeerTargets specifies the target number of peers in each state. Use 0 to use the default target, or -1 for unlimited. Default targets: known=150, established=50, active=20

func WithPledgeLeverage added in v0.67.0

func WithPledgeLeverage(enabled bool, leverage uint) ConfigOptionFunc

WithPledgeLeverage configures the CIP-50 pledge-leverage staking reward cap. It is consensus-affecting and disabled by default; enable it only on a network where every node also enables it. leverage is L, the maximum ratio of total stake to pledge, and is used only when enabled.

func WithPluginSelection added in v0.68.0

func WithPluginSelection(
	capability plugin.Capability,
	selection plugin.Selection,
) ConfigOptionFunc

WithPluginSelection selects and configures one plugin capability.

func WithPrometheusRegistry

func WithPrometheusRegistry(registry prometheus.Registerer) ConfigOptionFunc

WithPrometheusRegistry specifies a prometheus.Registerer instance to add metrics to. In most cases, prometheus.DefaultRegistry would be a good choice to get metrics working

func WithReconcileInterval added in v0.26.0

func WithReconcileInterval(d time.Duration) ConfigOptionFunc

WithReconcileInterval specifies how often the peer governor runs its reconciliation loop. Non-positive values are ignored. Default: 5m.

func WithRunMode added in v0.21.0

func WithRunMode(mode string) ConfigOptionFunc

WithRunMode sets the operational mode ("serve", "load", or "dev"). "dev" mode enables development behaviors (forge blocks, disable outbound).

func WithShelleyKESKey added in v0.22.0

func WithShelleyKESKey(path string) ConfigOptionFunc

WithShelleyKESKey specifies the path to the KES signing key file (CARDANO_SHELLEY_KES_KEY). Required for block production.

func WithShelleyOperationalCertificate added in v0.22.0

func WithShelleyOperationalCertificate(path string) ConfigOptionFunc

WithShelleyOperationalCertificate specifies the path to the operational certificate file (CARDANO_SHELLEY_OPERATIONAL_CERTIFICATE). Required for block production.

func WithShelleyVRFKey added in v0.22.0

func WithShelleyVRFKey(path string) ConfigOptionFunc

WithShelleyVRFKey specifies the path to the VRF signing key file (CARDANO_SHELLEY_VRF_KEY). Required for block production.

func WithShutdownTimeout added in v0.18.0

func WithShutdownTimeout(timeout time.Duration) ConfigOptionFunc

WithShutdownTimeout specifies the timeout for graceful shutdown. The default is 30 seconds

func WithStartEra added in v0.51.0

func WithStartEra(startEra string) ConfigOptionFunc

WithStartEra sets the experimental direct startup era. Empty uses the genesis protocol version; "dijkstra" starts directly in the Dijkstra era.

func WithStorageMode added in v0.22.0

func WithStorageMode(mode StorageMode) ConfigOptionFunc

WithStorageMode specifies the storage mode. StorageModeCore stores only consensus data; StorageModeAPI adds full transaction metadata for API queries.

func WithStrictUtxoValidation added in v0.61.2

func WithStrictUtxoValidation(strict bool) ConfigOptionFunc

WithStrictUtxoValidation specifies whether an unrecoverable consumed UTxO past the recorded Mithril sync boundary is a hard error rather than a silently skipped condition. See database.Config.StrictUtxoValidation.

func WithTopologyConfig

func WithTopologyConfig(
	topologyConfig *topology.TopologyConfig,
) ConfigOptionFunc

WithTopologyConfig specifies a topology.TopologyConfig to use for outbound peers

func WithTracing

func WithTracing(tracing bool) ConfigOptionFunc

WithTracing enables tracing. By default, spans are submitted to a HTTP(s) endpoint using OTLP. This can be configured using the OTEL_EXPORTER_OTLP_* env vars documented in the README for go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp

func WithTracingStdout

func WithTracingStdout(stdout bool) ConfigOptionFunc

WithTracingStdout enables tracing output to stdout. This also requires tracing to enabled separately. This is mostly useful for debugging

func WithUnsafeFullPotRewardsOnStandardNetworks added in v0.67.0

func WithUnsafeFullPotRewardsOnStandardNetworks(enabled bool) ConfigOptionFunc

WithUnsafeFullPotRewardsOnStandardNetworks allows CIP-0163 full-pot reward distribution on predefined standard networks. This is consensus-breaking unless the network has explicitly adopted the rule; leave disabled for normal operation.

func WithUtxorpcTlsCertFilePath added in v0.3.2

func WithUtxorpcTlsCertFilePath(path string) ConfigOptionFunc

WithUtxorpcTlsCertFilePath specifies the path to the TLS certificate for the gRPC API listener. This defaults to empty

func WithUtxorpcTlsKeyFilePath added in v0.3.2

func WithUtxorpcTlsKeyFilePath(path string) ConfigOptionFunc

WithUtxorpcTlsKeyFilePath specifies the path to the TLS key for the gRPC API listener. This defaults to empty

func WithValidateForgedBlock added in v0.58.0

func WithValidateForgedBlock(enabled bool) ConfigOptionFunc

WithValidateForgedBlock enables self-validation of locally-forged blocks before they are adopted onto the chain and diffused to peers. When enabled, the forger runs VRF/KES header crypto, body-hash consistency, and per-tx ledger validation on each forged block. A failing block is dropped without being adopted or diffused. Disabled by default.

func WithValidateHistorical added in v0.17.0

func WithValidateHistorical(validate bool) ConfigOptionFunc

WithValidateHistorical specifies whether to validate all historical blocks during ledger processing

type HistoryExpiryConfig added in v0.52.0

type HistoryExpiryConfig struct {
	Enabled   bool
	Frequency time.Duration
}

HistoryExpiryConfig controls local expiry of immutable block history.

type ListenerConfig

type ListenerConfig = connmanager.ListenerConfig

type MidnightConfig added in v0.55.0

type MidnightConfig struct {
	Port uint
	Host string

	CNightPolicyID              string
	CNightAssetName             string
	MappingValidatorAddress     string
	AuthTokenPolicyID           string
	AuthTokenAssetName          string
	CommitteeCandidateAddress   string
	TechnicalCommitteeAddress   string
	TechnicalCommitteePolicyID  string
	CouncilAddress              string
	CouncilPolicyID             string
	PermissionedCandidatePolicy string
}

MidnightConfig controls the Midnight indexer and optional gRPC listener. Indexing is only active in API storage mode. Port 0 disables the gRPC listener while leaving indexing eligible to run.

type Node

type Node struct {
	// contains filtered or unexported fields
}

func New

func New(cfg Config) (*Node, error)

func (*Node) Run

func (n *Node) Run(ctx context.Context) error

func (*Node) Stop

func (n *Node) Stop() error

type OffchainMetadataConfig added in v0.54.0

type OffchainMetadataConfig struct {
	HTTPClient            *http.Client
	Interval              time.Duration
	RequestTimeout        time.Duration
	UserAgent             string
	IPFSGatewayURL        string
	BatchSize             int
	MaxBytes              int64
	AllowPrivateAddresses bool
}

OffchainMetadataConfig controls API-mode off-chain metadata fetching. Zero values use the internal fetcher defaults.

type StorageMode added in v0.22.0

type StorageMode string

StorageMode controls how much data the metadata store persists.

const (
	// StorageModeCore stores only consensus and chain state data.
	// Witnesses, scripts, datums, redeemers, and tx metadata CBOR
	// are skipped. Suitable for block producers with no APIs.
	StorageModeCore StorageMode = "core"
	// StorageModeAPI stores everything needed for API queries
	// (blockfrost, utxorpc, mesh) in addition to core data.
	StorageModeAPI StorageMode = "api"
)

func (StorageMode) IsAPI added in v0.22.0

func (m StorageMode) IsAPI() bool

IsAPI returns true if the storage mode includes API data.

func (StorageMode) Valid added in v0.22.0

func (m StorageMode) Valid() bool

Valid returns true if the storage mode is a recognized value.

Directories

Path Synopsis
api
utxorpc
Package utxorpc implements Dingo's UTxO RPC server, serving the utxorpc.v1alpha.cardano gRPC API defined by the UTxO RPC spec.
Package utxorpc implements Dingo's UTxO RPC server, serving the utxorpc.v1alpha.cardano gRPC API defined by the UTxO RPC spec.
Package chain manages Dingo's blockchain state: the primary chain, any alternate (candidate) chains, fork detection, and rollback orchestration.
Package chain manages Dingo's blockchain state: the primary chain, any alternate (candidate) chains, fork detection, and rollback orchestration.
Package chainselection implements multi-peer chain selection.
Package chainselection implements multi-peer chain selection.
Package chainsync tracks the state of Dingo's block-synchronization sessions with connected peers.
Package chainsync tracks the state of Dingo's block-synchronization sessions with connected peers.
cmd
dingo command
config
Package connmanager owns the lifecycle of network connections between Dingo and its peers and clients.
Package connmanager owns the lifecycle of network connections between Dingo and its peers and clients.
consensus
praos
Package praos contains pure Praos chain-selection primitives: the select view projected from a Shelley-family block header, VRF output extraction, and the equal-length tiebreaker comparison functions that mirror ouroboros-consensus' PraosTiebreakerView and preferCandidate logic.
Package praos contains pure Praos chain-selection primitives: the select view projected from a Shelley-family block header, VRF output extraction, and the equal-length tiebreaker comparison functions that mirror ouroboros-consensus' PraosTiebreakerView and preferCandidate logic.
Package database is Dingo's storage abstraction.
Package database is Dingo's storage abstraction.
plugin/metadata/deferred
Package deferred holds the bulk-load deferred-index manifest in a stand-alone package so each metadata plugin (sqlite, mysql, postgres) can import it without pulling in the parent metadata package, which side-effect-imports every plugin and would create an import cycle.
Package deferred holds the bulk-load deferred-index manifest in a stand-alone package so each metadata plugin (sqlite, mysql, postgres) can import it without pulling in the parent metadata package, which side-effect-imports every plugin and would create an import cycle.
plugin/metadata/importutil
Package importutil provides shared helpers for metadata import operations across all database backends (sqlite, postgres, mysql).
Package importutil provides shared helpers for metadata import operations across all database backends (sqlite, postgres, mysql).
plugin/metadata/internal/collateralfee
Package collateralfee computes the fee-pot contribution of phase-2-invalid transactions.
Package collateralfee computes the fee-pot contribution of phase-2-invalid transactions.
plugin/metadata/internal/rewardstate
Package rewardstate holds reward_live_stake and reward snapshot metadata query logic shared by the sqlite, mysql, and postgres metadata plugins.
Package rewardstate holds reward_live_stake and reward snapshot metadata query logic shared by the sqlite, mysql, and postgres metadata plugins.
plugin/metadata/internal/sqldialect
Package sqldialect centralizes SQL-dialect literals shared by metadata query packages.
Package sqldialect centralizes SQL-dialect literals shared by metadata query packages.
plugin/metadata/internal/utxocond
Package utxocond builds fixed-shape "(tx_id = ? AND output_idx = ?)" OR-list conditions for the UTxO block-apply UPDATEs (consume, collateral, reference inputs) shared by the sqlite, postgres, and mysql metadata plugins.
Package utxocond builds fixed-shape "(tx_id = ? AND output_idx = ?)" OR-list conditions for the UTxO block-apply UPDATEs (consume, collateral, reference inputs) shared by the sqlite, postgres, and mysql metadata plugins.
plugin/metadata/pagination
Package pagination holds cursor-pagination helpers shared by the metadata plugin backends (sqlite, postgres, mysql).
Package pagination holds cursor-pagination helpers shared by the metadata plugin backends (sqlite, postgres, mysql).
Package event provides Dingo's EventBus: an in-process publish/ subscribe primitive that lets components communicate without holding references to each other.
Package event provides Dingo's EventBus: an in-process publish/ subscribe primitive that lets components communicate without holding references to each other.
internal
plugins
Package plugins contains application-composition registration for all providers compiled into this binary.
Package plugins contains application-composition registration for all providers compiled into this binary.
test/archive-demo/cmd/demo-fetch command
demo-fetch is a small CLI used by the archive-demo's demo.sh to make the BlockFetch step of the demo visible: it connects to a Dingo NtN endpoint, ChainSync-walks from origin to find a block at or past a requested slot, then BlockFetches that block and reports the byte count and elapsed time.
demo-fetch is a small CLI used by the archive-demo's demo.sh to make the BlockFetch step of the demo visible: it connects to a Dingo NtN endpoint, ChainSync-walks from origin to find a block at or past a requested slot, then BlockFetches that block and reports the byte count and elapsed time.
test/archive-demo/cmd/inspect-blob command
inspect-blob is a CLI used by the archive-demo integration test to verify whether a block (slot, hash) is present in a Dingo node's local Badger blob store.
inspect-blob is a CLI used by the archive-demo integration test to verify whether a block (slot, hash) is present in a Dingo node's local Badger blob store.
test/archive-demo/internal/archivedemo
Package archivedemo provides shared helpers for the archive-node demo at internal/test/archive-demo/.
Package archivedemo provides shared helpers for the archive-node demo at internal/test/archive-demo/.
test/conformance
Package conformance provides a DingoStateManager that implements the ouroboros-mock conformance.StateManager interface using dingo's database and ledger packages with an in-memory SQLite database.
Package conformance provides a DingoStateManager that implements the ouroboros-mock conformance.StateManager interface using dingo's database and ledger packages with an in-memory SQLite database.
test/dbtest
Package dbtest composes storage providers for tests that need a real database without putting provider construction back into package database.
Package dbtest composes storage providers for tests that need a real database without putting provider construction back into package database.
test/testutil
Package testutil provides common test helper utilities for the Dingo project.
Package testutil provides common test helper utilities for the Dingo project.
Package keystore provides key management for Cardano stake pool operators.
Package keystore provides key management for Cardano stake pool operators.
Package ledger owns Dingo's consensus-critical state: the UTxO set, protocol parameters, stake distribution, certificates, governance actions, epoch/nonce bookkeeping, and Plutus script execution.
Package ledger owns Dingo's consensus-critical state: the UTxO set, protocol parameters, stake distribution, certificates, governance actions, epoch/nonce bookkeeping, and Plutus script execution.
forging
Package forging contains types and utilities for block production.
Package forging contains types and utilities for block production.
hardfork
Package hardfork provides the HardFork Combinator primitives used by the ledger to reason about multi-era chain time, epoch, and slot conversions.
Package hardfork provides the HardFork Combinator primitives used by the ledger to reason about multi-era chain time, epoch, and slot conversions.
leader
Package leader provides Ouroboros Praos leader election functionality for block production.
Package leader provides Ouroboros Praos leader election functionality for block production.
leios
Package leios implements the CIP-0164 stake-truncated voting committee, stake-quorum vote tallying, and endorser-block certificate construction and validation.
Package leios implements the CIP-0164 stake-truncated voting committee, stake-quorum vote tallying, and endorser-block certificate construction and validation.
rewards
Package rewards implements the Shelley stake-pool reward calculation.
Package rewards implements the Shelley stake-pool reward calculation.
snapshot
Package snapshot provides stake snapshot management for Ouroboros Praos leader election.
Package snapshot provides stake snapshot management for Ouroboros Praos leader election.
Package mempool implements Dingo's transaction pool.
Package mempool implements Dingo's transaction pool.
indexer
Package indexer subscribes to ledger block events and indexes Midnight-relevant transactions (cNIGHT creates/spends, mapping-validator registrations/deregistrations, Technical Committee / Council governance datums, Ariadne permissioned-candidate parameters, and committee-candidate UTxO snapshots) into the database.
Package indexer subscribes to ledger block events and indexes Midnight-relevant transactions (cNIGHT creates/spends, mapping-validator registrations/deregistrations, Technical Committee / Council governance datums, Ariadne permissioned-candidate parameters, and committee-candidate UTxO snapshots) into the database.
server
Package server runs the MidnightState gRPC service.
Package server runs the MidnightState gRPC service.
Package ouroboros hosts Dingo's handlers for the Ouroboros mini- protocols: chainsync, blockfetch, txsubmission, keepalive, peer-sharing, handshake, and the Leios prototype protocols (LeiosFetch, LeiosNotify) when enabled.
Package ouroboros hosts Dingo's handlers for the Ouroboros mini- protocols: chainsync, blockfetch, txsubmission, keepalive, peer-sharing, handshake, and the Leios prototype protocols (LeiosFetch, LeiosNotify) when enabled.
Package peergov implements Dingo's peer governance: it decides who the node connects to, how many peers to maintain in each tier, and when to churn inactive peers out of the active set.
Package peergov implements Dingo's peer governance: it decides who the node connects to, how many peers to maintain in each tier, and when to churn inactive peers out of the active set.
Package plugin provides the instance-owned host for compiled-in Dingo plugins.
Package plugin provides the instance-owned host for compiled-in Dingo plugins.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL