8000 feat(queries): ratelimits by elee1766 · Pull Request #4359 · wormhole-foundation/wormhole · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

feat(queries): ratelimits #4359

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

Open
wants to merge 12 commits into
base: main
Choose a base branch
from

Conversation

elee1766
Copy link
@elee1766 elee1766 commented Apr 21, 2025

queryratelimit.Enforcer is in charge of storing rate limits and responding based off a policy

queryratelimit.PolicyProvider is in charge of providing policies, aka fetching from chain/config, cache, etc

i have implemented a policyprovider which uses ccqAllowedRequesters. we can test using this, the functionality should be similar, except that there is a rate limit now.

we could also read from a json file of map[common.Address]*Policy. it is trivial to write a policyproviderfetcher that would work based off this.

in the future we will write a policyprovider which will request the policies from chain for a given key

dependencies:

adds x/sync from a transitive -> direct dependency, for singleflight.

adds github.com/google/btree from a transitive -> direct dependency, for a sorted map implementation.

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.

1 participant
0