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

RFC: deduplicated incremental delivery #1052

Closed
wants to merge 46 commits into from

Conversation

yaacovCR
Copy link
Contributor

@yaacovCR yaacovCR commented Nov 6, 2023

Iterating on #1034 and #1026, removed mutation of internal state, event stream management, and the need for subprocedures.

YieldSubsequentPayloads now is passed the entirety of the "state," pending futures, etc, monitors for any changes to pending futures, rebuilds a new "state" representation based on any changes, yields a single result as necessary, and then recursively calls itself to yield remaining results.

[The diff to main might be helpful, but this is built on top of the amazing #742 and so the diff from that branch could be more useful.]

Copy link

netlify bot commented Nov 6, 2023

Deploy Preview for graphql-spec-draft ready!

Name Link
🔨 Latest commit a966583
🔍 Latest deploy log https://app.netlify.com/sites/graphql-spec-draft/deploys/65b8a893b199c20008bfb2cc
😎 Deploy Preview https://deploy-preview-1052--graphql-spec-draft.netlify.app/draft
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@yaacovCR yaacovCR marked this pull request as ready for review November 6, 2023 14:30
@yaacovCR yaacovCR force-pushed the deduplicate3 branch 6 times, most recently from 4e836eb to b5aa295 Compare November 7, 2023 09:59
@yaacovCR yaacovCR changed the title Deduplicated incremental delivery (without mutation of global state or subprocedures) RFC: deduplicated incremental delivery Nov 7, 2023
@yaacovCR yaacovCR force-pushed the deduplicate3 branch 5 times, most recently from fec902b to 9e13d28 Compare November 9, 2023 12:16
@yaacovCR
Copy link
Contributor Author

yaacovCR commented Nov 9, 2023

extracted out #1054 from this PR to simply a bit

@benjie benjie added the 💭 Strawman (RFC 0) RFC Stage 0 (See CONTRIBUTING.md) label Nov 27, 2023
@yaacovCR yaacovCR force-pushed the deduplicate3 branch 7 times, most recently from 0a801eb to 0f7b66f Compare December 4, 2023 12:37
…payload stream

The update stream suppresses future completion that should not lead to a response, i.e. now all incremental entries for a given fragment have been completed.

The payload stream does the response formatting.

NOTE: I think it is possible that we can move payload response formatting out of the execution section entirely, and into the Response section.
we start at the number of deferred fragments and then go down
have to update the pendingFutures set when completing a fragment
@yaacovCR
Copy link
Contributor Author

closing in favor of #1077, although that PR still describes only algorithmic changes, and additional work from #742 and this PR would have to be pulled in if the approach is adopted.

@yaacovCR yaacovCR closed this Feb 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
💭 Strawman (RFC 0) RFC Stage 0 (See CONTRIBUTING.md)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants