From 0b817b9ea8c0ff2e0c1083b92959f48d4943d61e Mon Sep 17 00:00:00 2001 From: Daniele Ahmed Date: Mon, 13 Mar 2023 14:26:10 +0100 Subject: [PATCH] Require order of request ID layers Signed-off-by: Daniele Ahmed --- .../aws-smithy-http-server/src/request/request_id.rs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/rust-runtime/aws-smithy-http-server/src/request/request_id.rs b/rust-runtime/aws-smithy-http-server/src/request/request_id.rs index eb4a706252f..9523f67aa3e 100644 --- a/rust-runtime/aws-smithy-http-server/src/request/request_id.rs +++ b/rust-runtime/aws-smithy-http-server/src/request/request_id.rs @@ -135,13 +135,14 @@ impl Layer for ServerRequestIdProviderLayer { } } -impl Service> for ServerRequestIdProvider +impl Service> for ServerRequestIdProvider> where - S: Service>, + S: Service, Response = Response>, + S::Future: std::marker::Send + 'static, { type Response = S::Response; type Error = S::Error; - type Future = S::Future; + type Future = ServerRequestIdResponseFuture; fn poll_ready(&mut self, cx: &mut Context<'_>) -> Poll> { self.inner.poll_ready(cx)