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
Copy file name to clipboardExpand all lines: codegen-server/src/main/kotlin/software/amazon/smithy/rust/codegen/server/smithy/protocols/ServerHttpBoundProtocolGenerator.kt
+24-2
Original file line number
Diff line number
Diff line change
@@ -136,6 +136,7 @@ private class ServerHttpBoundProtocolTraitImplGenerator(
136
136
"RuntimeError" to ServerRuntimeType.runtimeError(runtimeConfig),
137
137
"RequestRejection" to ServerRuntimeType.requestRejection(runtimeConfig),
138
138
"ResponseRejection" to ServerRuntimeType.responseRejection(runtimeConfig),
139
+
"PinProjectLite" to ServerCargoDependency.PinProjectLite.toType(),
139
140
"http" to RuntimeType.Http,
140
141
)
141
142
@@ -196,8 +197,27 @@ private class ServerHttpBoundProtocolTraitImplGenerator(
196
197
}
197
198
198
199
// Implement `from_request` trait for input types.
200
+
val inputFuture ="${inputSymbol.name}Future"
199
201
rustTemplate(
200
202
"""
203
+
// TODO(https://github.com/awslabs/smithy-rs/issues/2238): Remove the `Pin<Box<dyn Future>>` and replace with thin wrapper around `Collect`.
204
+
#{PinProjectLite}::pin_project! {
205
+
/// A [`Future`](std::future::Future) aggregating the body bytes of a [`Request`] and constructing the
206
+
/// [`${inputSymbol.name}`](#{I}) using modelled bindings.
0 commit comments