aptos-indexer-processors
aptos-indexer-processors copied to clipboard
Simplest MVP transaction filtering
an MVP version of the transaction filtering crate.
Performance
On a random 3mb proto of 1000txns during taptos, running the "everything" filter (looped) gives:
BENCH: Took 13.225167ms for 1000000 transactions (13ns each)
Random 10mb proto from April 25th with "everything" filter:
BENCH: Took 21.815375ms for 1000000 transactions (21ns each)
Graffio 100mb proto ("everything" filter, but with or):
BENCH: Took 31.559333ms for 1000000 transactions (31ns each)
More advanced feature complete version here: https://github.com/aptos-labs/aptos-indexer-processors/pull/392
How do we plan to share this crate with aptos-core?
@bowenyang007 sorry I don't understand the question
Data service needs to use this right? I'm curious if we're going to copy over the code or upload it to crates.io.
A few additional questions:
- Can we add a readme? Particularly I'm not sure from the PR what exactly is being filtered or how it's meant to be used.
- How are the proto fixtures supposed to work? How do we upgrade the proto?
- Can we have comments?
@bowenyang007 I figured we'd do it the way we do everything else, i.e;
transaction-filter = { git = "https://github.com/aptos-labs/aptos-indexer-processors.git", rev = "4541add3fd29826ec57f22658ca286d2d6134b93" }
I can move stuff to the readme and add an example, sure