feat: concurrent connection limits, from the first external contribution #28

Merged
chrnx merged 3 commits from contrib into develop 2026-08-10 13:41:10 +00:00
Owner

First contribution to land through the contrib route. Carries Expressive-Tea/green-tea#16 by @hgshreyas, which closes Expressive-Tea/green-tea#12.

Adds limits.maxConnections, defaulting to 1000 and mapped to Node's server.maxConnections. Values at or below zero leave Node unlimited, so opting out is possible without a magic sentinel — a literal cap of zero would otherwise refuse every connection, which is what a reader writing 0 for "off" would least expect. Deno and Bun expose no equivalent active-socket cap and say so rather than accepting an option that does nothing there.

Merged rather than rebased, deliberately. Now that develop and main are the same commit there is no main-only history for a merge to drag in, so rebasing would only rewrite the contributor's SHAs and push contrib out of ancestry — which then costs a force-push at reset time. This way his commits reach main under his own name and hash, and the contrib reset stays a fast-forward. AGENTS.md still tells the old story and needs correcting; that follows separately.

Verified locally before merge: typecheck clean, lint quiet, 360 tests, and a behavioural check that the server really does accept traffic at 0 and -1 rather than merely leaving the property unset.

First contribution to land through the `contrib` route. Carries Expressive-Tea/green-tea#16 by @hgshreyas, which closes Expressive-Tea/green-tea#12. Adds `limits.maxConnections`, defaulting to `1000` and mapped to Node's `server.maxConnections`. Values at or below zero leave Node unlimited, so opting out is possible without a magic sentinel — a literal cap of zero would otherwise refuse every connection, which is what a reader writing `0` for "off" would least expect. Deno and Bun expose no equivalent active-socket cap and say so rather than accepting an option that does nothing there. Merged rather than rebased, deliberately. Now that `develop` and `main` are the same commit there is no main-only history for a merge to drag in, so rebasing would only rewrite the contributor's SHAs and push `contrib` out of ancestry — which then costs a force-push at reset time. This way his commits reach `main` under his own name and hash, and the `contrib` reset stays a fast-forward. AGENTS.md still tells the old story and needs correcting; that follows separately. Verified locally before merge: typecheck clean, lint quiet, 360 tests, and a behavioural check that the server really does accept traffic at `0` and `-1` rather than merely leaving the property unset.
chrnx added 3 commits 2026-08-10 13:40:58 +00:00
Signed-off-by: hgshreyas <hgshreyas.cs24@bmsce.ac.in>
Signed-off-by: hgshreyas <hgshreyas.cs24@bmsce.ac.in>
Merge pull request #16 from hgshreyas/feature/max-connections
CI / build (push) Successful in 34s
CI / build (pull_request) Successful in 34s
024b0a79fd
feat: add concurrent connection limits
chrnx merged commit 61bef36d60 into develop 2026-08-10 13:41:10 +00:00
Sign in to join this conversation.