Skip to content

Add polling throttle test and document timeout logic#51

Closed
bbatsov wants to merge 1 commit intomasterfrom
add-polling-throttle-test
Closed

Add polling throttle test and document timeout logic#51
bbatsov wants to merge 1 commit intomasterfrom
add-polling-throttle-test

Conversation

@bbatsov
Copy link
Contributor

@bbatsov bbatsov commented Feb 19, 2026

Followup to the GET flood fix (8663445). Adds a test that spins up a
server with a request counter and verifies GET polling stays bounded
(< 15 requests over a 500ms window). Also adds a comment to the read
function explaining the polling strategy and the 100ms backoff cap.

Fixes #10

Add a test that verifies GET request count stays bounded during
polling (< 15 over 500ms, vs 50+ without throttle). Add a comment
to the read function explaining the polling strategy.

Also clean up client_test.clj to follow Clojure testing conventions:
group related assertions under testing blocks, extract with-client
macro to reduce boilerplate, make helpers private, use
clojure.string/starts-with? over Java interop.
bbatsov added a commit that referenced this pull request Feb 19, 2026
Add a test that verifies GET request count stays bounded during
polling (< 15 over 500ms, vs 50+ without throttle). Add a comment
to the read function explaining the polling strategy.

Also clean up client_test.clj to follow Clojure testing conventions:
group related assertions under testing blocks, extract with-client
macro to reduce boilerplate, make helpers private, use
clojure.string/starts-with? over Java interop.

Fixes #10
@bbatsov bbatsov closed this Feb 19, 2026
@bbatsov bbatsov deleted the add-polling-throttle-test branch February 19, 2026 16:18
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.

GET floods

1 participant