Note: Run these commands from the root of the project
docker compose up db redis prometheus
INIT_FILE_PATH=./init.sql sea migrate up --database-url=postgres://solana:solana@localhost:5432/solana
Config for grpc2redis ./config-grpc2redis.yml
This service will listen to geyser gRPC account and transaction updates. It makes multiple subscriptions to the gRPC stream and filter the data based on the config. The data (vec of bytes) is pushed to a pipeline and then flushed to redis at regular intervals.
Note: Log level can be set to
info
,debug
,warn
,error
RUST_LOG=info cargo run --bin das-grpc-ingest -- --config grpc-ingest/config-grpc2redis.yml grpc2redis
Config for Ingester ./config-ingester.yml
This service performs many concurrent tasks
- Fetch account updates from redis and process them using using program_transformer
- Fetch transaction updates from redis and processe them
- Fetch snapshots from redis and process them
- download token metedata json and store them in postgres db
RUST_LOG=debug,sqlx=warn cargo run --bin das-grpc-ingest -- --config grpc-ingest/config-ingester.yml ingester
Both grpc2redis and ingester services expose prometheus metrics and can be accessed at http://localhost:9090/metrics