Skip to content

Commit e7aeb67

Browse files
authored
Merge pull request #32 from DIMO-Network/pr-3898-templates-abi
Pr 3898 templates abi
2 parents fc7a6aa + 3621dd9 commit e7aeb67

File tree

6 files changed

+1462
-2
lines changed

6 files changed

+1462
-2
lines changed

README.md

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,24 @@ contracts:
1818
abi: charts/contract-event-processor/abi/VehicleId.json
1919
```
2020
21+
## Managing ABIs
22+
23+
To optimize performance and reduce processing overhead, we recommend filtering the contract ABIs to include only the events that the processor will actually use. This prevents the service from processing unnecessary events and reduces memory usage.
24+
25+
### Filtering ABIs by Events
26+
27+
You can use the following commands to filter ABI files:
28+
29+
Filter all events from an ABI:
30+
```bash
31+
jq -c 'map(select(.type == "event"))' abi.json
32+
```
33+
34+
Filter specific events by name:
35+
```bash
36+
jq -c 'map(select(.type == "event" and .name == "EventName"))' abi.json
37+
```
38+
2139
## Getting Set Up
2240

2341
1. If you don't already have an API key, you can request one [here](https://docs.alchemy.com/docs/alchemy-quickstart-guide)

0 commit comments

Comments
 (0)