Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: mutex for searching transactions #98

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

PhearZero
Copy link
Member

Proposed Changes

  • Add a Mutex to the chunked filter

This could be a Semaphore with known safe number of in-flight requests. For now I've made it a Mutex just to continue testing the library.

@robdmoore
Copy link
Contributor

Assume this is to stop bulk requests being sent to indexer api in parallel?

To your point there is a balancing act here, might want to have a certain number in parallel to speed things up without DoSing the API?

@PhearZero
Copy link
Member Author

Exactly, I had about a dozen accounts as filters and it was rate limiting. Reached for a Semaphore since it has been useful in this context.

There could be a better way to limit in-flight requests but the Semaphore could still be useful as a fail safe

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants