-
Notifications
You must be signed in to change notification settings - Fork 65
Add RFC for incremental delivery #124
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
Conversation
|
||
----- | ||
``` | ||
* The boundary used is `-` and is passed to the client in the http response's content-type header. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I co not see this in the example above.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The content-type: multipart/mixed; boundary="-"
header should be in the HTTP response headers. The example is the HTTP response body. Each part of the response body contains it's own set of headers, but the header defining the boundary needs to be on the HTTP response, not in the body.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it's worth mentioning
Pretty interesting; I'll have to think about how this fits in with the GraphQL multipart request spec 🤔 @robrichard have you considered how they could be unified? E.g. someone using |
@jaydenseric I don't think there will be any conflict with the multipart request spec, since that spec only defines the request format, and this spec only describes the response format. Should be able to use |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it ready to be merged.
On last GraphQL WG we agreed to add support @stream/@defer
across the stack.
|
||
## `content-type: multipart/mixed` | ||
|
||
The HTTP response for an incrementally delivered response should contain the `content-type: multipart/mixed; boundary="-"` response header and conform to the [specification of multipart content defined by the W3 in rfc1341](https://www.w3.org/Protocols/rfc1341/7_2_Multipart.html). An example response body will look like: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Must the boundary be "-"
specifically? Could other boundaries be used?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should support arbitrary boundaries. fetch-multipart-graphql currently only supports "-"
but I will update that and this document to allow any boundary.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@benjie @robrichard Sorry, I didn't notice this comment before merging.
On the last "GraphQL over HTTP" WG we decided on merging and just forgot to actually do it.
Hope it didn't disrupt your workflow and @benjie suggestion can be addressed as separate PR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've filed an issue here: #135 (@IvanGoncharov if you could assign it to @robrichard that would be helpful).
@jaydenseric to clarify, i think what @robrichard is saying is that non-file fields can use @jaydenseric speaking of which, would love to help advance file spec, and maybe we can revisit how |
No description provided.