dingo

package module
v0.22.0 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2026 License: Apache-2.0 Imports: 39 Imported by: 0

README

Dingo

Dingo Logo
GitHub Go Report Card Go Reference Discord

Dingo

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 API servers: UTxO RPC, Blockfrost-compatible REST, Mesh (Coinbase Rosetta)

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_UTXORPC_PORT
    • TCP port to bind for listening for UTxO RPC (default: 0, disabled)
  • DINGO_BLOCKFROST_PORT
    • TCP port for the Blockfrost-compatible REST API (default: 0, disabled)
  • DINGO_MESH_PORT
    • TCP port for the Mesh (Coinbase Rosetta) API (default: 0, disabled)
  • DINGO_BARK_PORT
    • TCP port for the Bark block archive API (default: 0, disabled)
  • 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 protocol support)
  • 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

Fast Bootstrapping with Mithril

Instead of syncing from genesis (which can take days on mainnet), you can bootstrap Dingo using a Mithril snapshot. There are two approaches depending on your use case:

Approach Command Use Case Data Available
dingo sync --mithril dingo sync --mithril Consensus nodes, relays Current ledger state + all blocks
mithril-client + dingo load Manual download + load Indexers, API nodes Full historical transaction/certificate data

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 <digest>

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

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

What is NOT included: Individual transaction records, certificate history, witness/script/datum storage, and governance vote records for blocks before the snapshot. These are not needed for consensus, block production, or serving blocks to peers. New blocks processed after bootstrap will have full metadata.

Performance (preview network, ~4M blocks):

Phase Time
Download snapshot (~2.6 GB) ~1-2 min
Extract + download ancillary ~1 min
Import ledger state (UTxOs, accounts, pools, DReps, epochs) ~12 min
Load blocks into blob store ~36 min
Total ~50 min
Option 2: mithril-client + dingo load (For Indexers/API Nodes)

If you need full historical data (transaction lookups, certificate queries, datum/script resolution), use the external mithril-client to download the snapshot and then load it with dingo load, which processes every block through the full indexing pipeline.

Prerequisites

Install the mithril-client CLI from Mithril releases:

# Detect OS and architecture
OS=$(uname -s)
ARCH=$(uname -m)

case "$OS" in
  Linux)
    case "$ARCH" in
      x86_64)  MITHRIL_PLATFORM="x64-linux-musl" ;;
      aarch64|arm64) MITHRIL_PLATFORM="arm64-linux-musl" ;;
      *) echo "Unsupported architecture: $ARCH"; exit 1 ;;
    esac
    ;;
  Darwin)
    case "$ARCH" in
      x86_64)  MITHRIL_PLATFORM="x64-macos" ;;
      arm64)   MITHRIL_PLATFORM="arm64-macos" ;;
      *) echo "Unsupported architecture: $ARCH"; exit 1 ;;
    esac
    ;;
  *) echo "Unsupported OS: $OS (see Mithril releases for Windows)"; exit 1 ;;
esac

MITHRIL_VERSION="2506.0"
curl -L "https://github.com/input-output-hk/mithril/releases/download/${MITHRIL_VERSION}/mithril-${MITHRIL_VERSION}-${MITHRIL_PLATFORM}.tar.gz" -o mithril.tar.gz
tar -xzf mithril.tar.gz
sudo mv mithril-client /usr/local/bin/
rm mithril.tar.gz

For Windows, download the appropriate binary from the Mithril releases page.

Bootstrap Workflow
# Set network (CARDANO_NETWORK is used by dingo, not mithril-client)
export CARDANO_NETWORK=preview
# AGGREGATOR_ENDPOINT is used by mithril-client
export AGGREGATOR_ENDPOINT=https://aggregator.pre-release-preview.api.mithril.network/aggregator

# For mainnet:
# export AGGREGATOR_ENDPOINT=https://aggregator.release-mainnet.api.mithril.network/aggregator

# Download snapshot (uses AGGREGATOR_ENDPOINT)
mithril-client cardano-db download --download-dir /tmp/mithril-snapshot

# Load into Dingo (uses CARDANO_NETWORK for chain config)
./dingo load /tmp/mithril-snapshot/db/immutable

# Clean up snapshot
rm -rf /tmp/mithril-snapshot

# Start Dingo
./dingo -n preview serve

This creates full historical data including transaction records, certificate history, witness data, scripts, datums, and governance votes -- everything needed for rich query APIs.

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

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_DATABASE_BLOB_PLUGIN=gcs
DINGO_DATABASE_METADATA_PLUGIN=sqlite

# Configuration file (dingo.yaml)
database:
  blob:
    plugin: "gcs"
  metadata:
    plugin: "sqlite"
Plugin Configuration

Each plugin supports specific configuration options. See dingo.yaml.example for detailed configuration examples.

BadgerDB Options:

  • data-dir - Directory for database files
  • block-cache-size - Block cache size in bytes
  • index-cache-size - Index cache size in bytes
  • gc - Enable garbage collection

Google Cloud Storage Options:

  • bucket - GCS bucket name
  • project-id - Google Cloud project ID
  • prefix - Path prefix within bucket

AWS S3 Options:

  • bucket - S3 bucket name
  • region - AWS region
  • prefix - Path prefix within bucket
  • access-key-id - AWS access key ID (optional - uses default credential chain if not provided)
  • secret-access-key - AWS secret access key (optional - uses default credential chain if not provided)

SQLite Options:

  • data-dir - Path to SQLite database file

PostgreSQL Options:

  • host - PostgreSQL server hostname
  • port - PostgreSQL server port
  • username - Database user
  • password - Database password
  • database - Database name

MySQL Options:

  • host - MySQL server hostname
  • port - MySQL server port
  • user - Database user
  • password - Database password
  • database - Database name
  • ssl-mode - MySQL TLS mode (mapped to tls= in DSN)
  • timezone - MySQL time zone location (default: UTC)
  • dsn - Full MySQL DSN (overrides other options when set)
  • storage-mode - Storage tier: core or api (default: core)
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.

Example

Running on mainnet:

CARDANO_NETWORK=mainnet CARDANO_CONFIG=path/to/cardano/configs/mainnet/config.json ./dingo

Note: you can find cardano configuration files at https://github.com/blinklabs-io/docker-cardano-configs/tree/main/config

Dingo will drop a dingo.socket file which can be used by other clients, such as cardano-cli or software like adder or kupo. This has only had limited testing, so success/failure reports are very welcome and encouraged!

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)
    • Blockfrost-compatible REST API
    • Mesh (Coinbase Rosetta) API
    • Bark block archive 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.24 or later. You also need make.

# Build
make
# Run
./dingo

You can also run the code without building a binary, first

go run ./cmd/dingo/

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=3, gossip=12, ledger=5

func WithBarkBaseUrl added in v0.22.0

func WithBarkBaseUrl(baseUrl string) ConfigOptionFunc

func WithBarkPort added in v0.22.0

func WithBarkPort(port uint) ConfigOptionFunc

func WithBarkSecurityWindow added in v0.22.0

func WithBarkSecurityWindow(window uint64) 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 WithBlobPlugin added in v0.21.0

func WithBlobPlugin(plugin string) ConfigOptionFunc

WithBlobPlugin specifies the blob storage plugin to use.

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 WithBlockfrostPort added in v0.22.0

func WithBlockfrostPort(port uint) ConfigOptionFunc

WithBlockfrostPort specifies the port for the Blockfrost-compatible REST API server. The server binds to the node's bindAddr on this port. 0 disables the server (default).

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 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 30 seconds.

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 WithEvictionWatermark added in v0.22.0

func WithEvictionWatermark(
	watermark float64,
) ConfigOptionFunc

WithEvictionWatermark sets the mempool eviction watermark as a fraction of capacity (0.0-1.0). When a new TX would push the mempool past this fraction, oldest TXs are evicted to make room. Default is 0.90 (90%).

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 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 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 WithMempoolCapacity added in v0.13.0

func WithMempoolCapacity(capacity int64) ConfigOptionFunc

WithMempoolCapacity sets the mempool capacity (in bytes)

func WithMeshPort added in v0.22.0

func WithMeshPort(port uint) ConfigOptionFunc

WithMeshPort specifies the port for the Mesh (Coinbase Rosetta) compatible REST API server. The server binds to the node's bindAddr on this port. 0 disables the server (default).

func WithMetadataPlugin added in v0.21.0

func WithMetadataPlugin(plugin string) ConfigOptionFunc

WithMetadataPlugin specifies the metadata storage plugin to use.

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 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 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 WithRejectionWatermark added in v0.22.0

func WithRejectionWatermark(
	watermark float64,
) ConfigOptionFunc

WithRejectionWatermark sets the mempool rejection watermark as a fraction of capacity (0.0-1.0). New TXs are rejected when the mempool would exceed this fraction even after eviction. Default is 0.95 (95%).

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 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 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 WithUtxorpcPort added in v0.2.2

func WithUtxorpcPort(port uint) ConfigOptionFunc

WithUtxorpcPort specifies the port to use for the gRPC API listener. 0 disables the server (default)

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 WithValidateHistorical added in v0.17.0

func WithValidateHistorical(validate bool) ConfigOptionFunc

WithValidateHistorical specifies whether to validate all historical blocks during ledger processing

type ListenerConfig

type ListenerConfig = connmanager.ListenerConfig

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 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
cmd
dingo command
config
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).
internal
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/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.
forging
Package forging contains types and utilities for block production.
Package forging contains types and utilities for block production.
leader
Package leader provides Ouroboros Praos leader election functionality for block production.
Package leader provides Ouroboros Praos leader election functionality for block production.
snapshot
Package snapshot provides stake snapshot management for Ouroboros Praos leader election.
Package snapshot provides stake snapshot management for Ouroboros Praos leader election.

Jump to

Keyboard shortcuts

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