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

Weird runtime behavior when sending many HTTP requests at the same time (limit of 256) #12214

Closed
sean-kuzco opened this issue Jun 27, 2024 · 1 comment
Labels
bug Something isn't working needs triage

Comments

@sean-kuzco
Copy link

What version of Bun is running?

1.1.8+89d25807f

What platform is your computer?

Darwin 23.5.0 arm64 arm

What steps can reproduce the bug?

Try to send many network requests (e.g. 1,000+) in a script run with Bun.

What is the expected behavior?

All requests would be sent to the server (the behavior if the script is run with NodeJS).

What do you see instead?

Requests are apparently sent with a limit of 256.

Additional information

We have a minimal reproduction of this behavior with more information here: https://github.com/context-labs/kuzco-bun-bug-reproduction

@sean-kuzco sean-kuzco added bug Something isn't working needs triage labels Jun 27, 2024
@sean-kuzco
Copy link
Author

We discovered this is because of a default concurrency limit of 256 for Bun's HTTP implementation, which can be configured with the BUN_CONFIG_MAX_HTTP_REQUESTS environment variable.

This PR changes the default to be consistent with NodeJS: #12221

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working needs triage
Projects
None yet
Development

No branches or pull requests

1 participant