From 2f26ec85241c925cecfbeb02daaf34b44c09c28a Mon Sep 17 00:00:00 2001 From: Matas Date: Fri, 1 Sep 2023 08:13:14 -0500 Subject: [PATCH] misc: add Kinesis SubscribeToShard E2E test (#1030) --- .../protocols/eventstream/EventStreamParserGenerator.kt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/codegen/smithy-aws-kotlin-codegen/src/main/kotlin/aws/sdk/kotlin/codegen/protocols/eventstream/EventStreamParserGenerator.kt b/codegen/smithy-aws-kotlin-codegen/src/main/kotlin/aws/sdk/kotlin/codegen/protocols/eventstream/EventStreamParserGenerator.kt index d46ea080e..a06943bc5 100644 --- a/codegen/smithy-aws-kotlin-codegen/src/main/kotlin/aws/sdk/kotlin/codegen/protocols/eventstream/EventStreamParserGenerator.kt +++ b/codegen/smithy-aws-kotlin-codegen/src/main/kotlin/aws/sdk/kotlin/codegen/protocols/eventstream/EventStreamParserGenerator.kt @@ -62,11 +62,11 @@ class EventStreamParserGenerator( // we just need to deserialize the event stream member (and/or the initial response) writer.withBlock( // FIXME - revert to private, exposed as internal temporarily while we figure out integration tests - "internal suspend fun #L(builder: #T.Builder, body: #T) {", + "internal suspend fun #L(builder: #T.Builder, call: #T) {", "}", op.bodyDeserializerName(), outputSymbol, - RuntimeTypes.Http.HttpBody, + RuntimeTypes.Http.HttpCall, ) { renderDeserializeEventStream(ctx, op, writer) } @@ -81,7 +81,7 @@ class EventStreamParserGenerator( val messageTypeSymbol = RuntimeTypes.AwsEventStream.MessageType val baseExceptionSymbol = ExceptionBaseClassGenerator.baseExceptionSymbol(ctx.settings) - writer.write("val chan = body.#T() ?: return", RuntimeTypes.Http.toSdkByteReadChannel) + writer.write("val chan = call.response.body.#T(call) ?: return", RuntimeTypes.Http.toSdkByteReadChannel) writer.write("val frames = #T(chan)", RuntimeTypes.AwsEventStream.decodeFrames) if (ctx.protocol.isRpcBoundProtocol) { renderDeserializeInitialResponse(ctx, output, writer)