Hydra Processor
Hydra processor is a client-side 'sink' tool used to fetch substrate events from a Hydra indexer. It sequentially applies the event handlers one by one in the order the events have been emitted.
Commands
hydra-processor help [COMMAND]
hydra-processor help [COMMAND]
display help for hydra-processor
See code: @oclif/plugin-help
hydra-processor migrate
hydra-processor migrate
hydra-processor run
hydra-processor run
Qickstart
Before the first run, the processor should set up auxiliary database tables required for its work:
Then hydra-processor
can be run against the manifest file (by default, it looks up manifest.yml
in the current folder)
Environment variables
Hydra processor requires a manifest file and certain environment variables to be set.
Variable | Default | Required | Description |
INDEXER_ENDPOINT_URL | - | Yes | Hydra indexer endpoint to source the raw event and extrinsic data |
MANIFEST_PATH | manifest.yml | No | Path to the manifest file |
DB_NAME | - | Yes | Database name |
DB_PORT | - | Yes | Database port |
DB_HOST | - | Yes | Database host |
DB_USER | - | Yes | Database user |
DB_PASS | - | Yes | Database password |
PROMETHEUS_PORT | 3000 | No | A prometheus metrics endpoint is started at this port |
POLL_INTERVAL_MS | 1 sec (60000 msec) | No | How often the processor polls the indexer for new blocks |
The required variables can either be set externally or loaded from a file using the -e
flag, e.g.:
Manifest file
The manifest file describes which and how the events and extrinsics should be processed. Here is an example for Kusama blockchain:
Last updated