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

feat: Add support for event stream initial-request to RPC-based protocols #1172

Closed
2 tasks
Tracked by #976
dayaffe opened this issue Oct 5, 2023 · 3 comments
Closed
2 tasks
Tracked by #976
Assignees
Labels
feature-request A feature should be added or improved.
Milestone

Comments

@dayaffe
Copy link
Contributor

dayaffe commented Oct 5, 2023

Describe the feature

Initial messages are defined in the Smithy spec here: https://smithy.io/2.0/spec/streaming.html#initial-messages

Determine how initial request should be handled for RPC protocols and implement.

Depends on #1175

Use Case

To correctly handle initial request and make values easily available to stream consumers.

Proposed Solution

Once support for unbounded Event Stream payloads (RPC) is completed, initial-request can be supported by parsing initial request members (members in the request w/o @streaming trait) within the HttpMiddleware. In order to ensure that initail-request members are processed first by the intended service, these values should be added to a message with event-type 'initial-request' and pre-pended to the event stream before it is sent (as was done by the Kotlin SDK here).

Other Information

Implementing support for initial-request in RPC protocol-based event streams will first require adding support for unbounded event stream payloads (RPC). Currently, Event Streams (in request) in the Swift SDK are only supported over REST protocols where they are bound with @httpPayload.

Acknowledgements

  • I may be able to implement this feature request
  • This feature might incur a breaking change
@dayaffe dayaffe added this to the GA milestone Oct 10, 2023
@dayaffe dayaffe added feature-request A feature should be added or improved. needs-triage This issue or PR still needs to be triaged. labels Oct 10, 2023
@sichanyoo
Copy link
Contributor

sichanyoo commented Oct 16, 2023

Effort is approximated assuming ticket #1175 is implemented.

@sichanyoo
Copy link
Contributor

sichanyoo commented Oct 16, 2023

Quip doc with details: /e7tTALANYJ03/Event-Streams-Knowledge-Document

@sichanyoo sichanyoo removed the needs-triage This issue or PR still needs to be triaged. label Oct 16, 2023
@sichanyoo sichanyoo self-assigned this Feb 12, 2024
@sichanyoo sichanyoo changed the title [Implementation] (Event Streams) Support initial-request in RPC-based protocols feat: Add support for event stream initial-request to RPC-based protocols Mar 1, 2024
@jbelkins
Copy link
Contributor

jbelkins commented Apr 9, 2024

Shipped in AWS SDK for Swift 0.40.0

@jbelkins jbelkins closed this as completed Apr 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature-request A feature should be added or improved.
Projects
None yet
Development

No branches or pull requests

3 participants