provider-http: SSE Last-Event-ID can advance past undelivered events after an oversized event
Maintainers usually reply within 1 day
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 74/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- typescript
- Domain
- networking
Research direction
Start with packages/provider-http/src/channels.ts, especially SseChannel.consume and SseIdTracker, then find the existing SSE reconnect tests. Add the described same-chunk regression case and ensure the tracker uses config.maxBytes. Done means reconnecting after the oversized event does not send a Last-Event-ID past an undelivered event.
Written by the indexing model from the issue text.
Description
Follow-up from the #89 review (head 9002547).
packages/provider-http/src/channels.ts SseChannel.consume: each chunk goes to this.ids.feed(text) before parser.feed(text). When eventsource-parser hits max-buffer-size-exceeded, onError throws mid-chunk, so events after the oversized one in that chunk are never delivered, but SseIdTracker has already processed the whole chunk and moved lastEventId past them. On reconnect Last-Event-ID makes the server skip those events: silent data loss on resume.
Also, SseIdTracker's maxLineLength (1 MiB default) is not tied to config.maxBytes, so the two scanners can disagree about very long lines.
Fix: feed the parser first and the tracker only if it didn't throw (resuming from the previous chunk's id replays a few events, which is better than losing them), or advance the id from inside the parser's line callbacks. Pass maxBytes to SseIdTracker. Add a test: an oversized event, then a good event with an id, in one chunk; after reconnect, the Last-Event-ID must not be past the undelivered event.
- Dominant language
- TypeScript
- Stars
- 0
- Forks
- 0
- Avg merge
- 14h 55m
- Merged PRs (30d)
- 26
Getting set up
- No Dockerfile or Docker Compose file
- No pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from hyperdrive-technology/holodeck
-
area:holodeck review-finding
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
hyperdrive-technology/holodeck#142 ·
Maintainers usually reply within 1 day
-
area:holodeck review-finding
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
hyperdrive-technology/holodeck#141 ·
Maintainers usually reply within 1 day
-
review-finding
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
hyperdrive-technology/holodeck#106 ·
Maintainers usually reply within 1 day
-
review-finding
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
hyperdrive-technology/holodeck#105 ·
Maintainers usually reply within 1 day
-
assetUrlProblem: data:image check uses the un-normalised URL, so ' data:image/png...' is rejectedOpenarea:holodeck review-finding
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
hyperdrive-technology/holodeck#104 ·
Maintainers usually reply within 1 day
All issues in hyperdrive-technology/holodeck
Similar issues
-
documentation
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
components-web-app/docs#260 ·
-
Difficulty 1/5 Under an hour Newbie friendliness 65/100
521xueweihan/HelloGitHub#4025 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
ctrf-io/playwright-ctrf-json-reporter#117 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
voidzero-dev/void#478 ·
Maintainers usually reply within 1 day