Hydra Processor is a '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.
undefined
USAGE
$ hydra-processor migrate
OPTIONS
-e, --env=env [default: .env] Path to a file with environment variables
undefined
USAGE
$ hydra-processor run
OPTIONS
-e, --env=env [default: .env] Path to a file with environment variables
-m, --manifest=manifest [default: manifest.yml] Manifest file
--id=id ID of the processor (useful for multi-processor setups)
--indexer=indexer Indexer URL to source events
hydra-processor
is driven by environment variables (loaded from .env
file or supplied by a shell)
and by settings from manifest.yml
(by default, it looks up manifest.yml
in the current folder).
Before the first run, the processor should set up auxiliary database tables required for its work:
hydra-processor migrate
Then processing may be started:
hydra-processor run
Variable | Default | Required | Description |
---|---|---|---|
INDEXER_ENDPOINT_URL | - | Yes | Hydra indexer endpoint to source the raw event and extrinsic data |
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 manifest file describes which and how the events and extrinsics should be processed. See mappings for more details.