mirror of
https://github.com/grassrootseconomics/eth-tracker.git
synced 2025-02-23 08:02:16 +01:00
docs: add NATS details
This commit is contained in:
parent
b92380bf91
commit
5d8dd60dca
29
README.md
29
README.md
@ -46,6 +46,11 @@ nano .env.example
|
||||
mv .env.example .env
|
||||
```
|
||||
|
||||
Special env variables:
|
||||
|
||||
* DEV=*
|
||||
* FORCE_BACKFILL=*
|
||||
|
||||
Refer to [`config.toml`](config.toml) to understand different config value settings.
|
||||
|
||||
|
||||
@ -55,6 +60,30 @@ Refer to [`config.toml`](config.toml) to understand different config value setti
|
||||
docker run --env-file .env -p 127.0.0.1:5001:5001 celo-tracker:latest
|
||||
```
|
||||
|
||||
## Processing NATS messages
|
||||
|
||||
### JSON structure
|
||||
|
||||
```js
|
||||
{
|
||||
"block": Number,
|
||||
"contractAddress": String,
|
||||
"success": Boolean,
|
||||
"timetamp" Number,
|
||||
"transactionHash": String,
|
||||
"transactionType": String,
|
||||
"payload": Object
|
||||
}
|
||||
```
|
||||
|
||||
### Monitoring with NATS CLI
|
||||
|
||||
Install NATS CLI from [here](https://github.com/nats-io/natscli?tab=readme-ov-file#installation).
|
||||
|
||||
```bash
|
||||
nats subscribe "TRACKER.*"
|
||||
```
|
||||
|
||||
## Caveats
|
||||
|
||||
* Reverted transactions older than 10 minutes will be skipped due to the trie potentially missing. To override this behavior, use an archive node and set `chain.archive_node` to `true`.
|
||||
|
Loading…
Reference in New Issue
Block a user