Implement block enqueue generic function map
Closed this issue · 1 comments
pharr117 commented
We need a more generic way to enqueue blocks that can be used with multiple options.
This will also support custom block event enqueue development for custom indexer implementations where the developer wants to customize how blocks are pulled in.
We may be able to come up with a generic function map that is used to gather blocks. Something like either:
- A generic GetBlockToEnqueue that gets global contextual data and returns the next block
- A generic function map that takes in global data and a channel and passes blocks over the channel (like how the current block enqueue methods work) - the base indexer would have less control using this method
pharr117 commented
This issue was implemented in #38 in a slightly different way. The block enqueue functionality can now be rewritten and applied to the indexer struct before the execution of the command. This allows custom block enqueue methods to be written that will be used instead of the default set of block enqueue functions made available by the package.