-
Notifications
You must be signed in to change notification settings - Fork 37
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
Add request rate limit to proxy #227
Conversation
Now you need to fix tests (it is better to add some test for rate limit too) and we are ready to merge. You can run tests by You also need to fix ESLint warnings by calling |
@@ -8,7 +8,7 @@ | |||
}, | |||
"scripts": { | |||
"start": "tsx watch index.ts", | |||
"test": "FORCE_COLOR=1 pnpm run /^test:/", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Changed it for the dev purposes, gonna add this line back in the next commit.
Pull request auto-reviewer [ ] If you added a new dependency, check our requirements. |
Fixes #168
I sort of tested this by running the proxy and spamming it with batches of requests (like this). It works on my machine™, but
pnpm test
doesn't quite agree with it.Would love to hear any sort of feedback on this, because I'm not sure if I'm moving in the right direction or not.
Additional changes: proxy config and error handling have been divorced from the
createProxyServer
implementation.