You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/// - Parameter decoder: The decoder object that will be used to decode the incoming `ByteBuffer` event into the generic `Event` type. `JSONDecoder()` used as default.
/// Write a response part into the stream. Bytes written are streamed continually.
50
50
/// - Parameter buffer: The buffer to write.
51
51
func write(_ buffer:ByteBuffer)asyncthrows
@@ -64,7 +64,7 @@ public protocol LambdaResponseStreamWriter {
64
64
///
65
65
/// - note: This handler protocol does not support response streaming because the output has to be encoded prior to it being sent, e.g. it is not possible to encode a partial/incomplete JSON string.
66
66
/// This protocol also does not support the execution of background work after the response has been returned -- the ``LambdaWithBackgroundProcessingHandler`` protocol caters for such use-cases.
67
-
publicprotocolLambdaHandler{
67
+
publicprotocolLambdaHandler:Sendable{
68
68
/// Generic input type.
69
69
/// The body of the request sent to Lambda will be decoded into this type for the handler to consume.
70
70
associatedtypeEvent:Decodable
@@ -86,7 +86,7 @@ public protocol LambdaHandler {
86
86
/// ``LambdaResponseWriter``that is passed in as an argument, meaning that the
87
87
/// ``LambdaWithBackgroundProcessingHandler/handle(_:outputWriter:context:)`` function is then
88
88
/// free to implement any background work after the result has been sent to the AWS Lambda control plane.
/// The body of the request sent to Lambda will be decoded into this type for the handler to consume.
92
92
associatedtypeEvent:Decodable
@@ -110,7 +110,7 @@ public protocol LambdaWithBackgroundProcessingHandler {
110
110
/// Used with ``LambdaWithBackgroundProcessingHandler``.
111
111
/// A mechanism to "return" an output from ``LambdaWithBackgroundProcessingHandler/handle(_:outputWriter:context:)`` without the function needing to
112
112
/// have a return type and exit at that point. This allows for background work to be executed _after_ a response has been sent to the AWS Lambda response endpoint.
0 commit comments