From c90e36a93e4ea1458be60d26dfedb5283118f454 Mon Sep 17 00:00:00 2001 From: myyrakle Date: Wed, 1 Jan 2025 23:06:28 +0900 Subject: [PATCH] =?UTF-8?q?[#209]=20=EB=B6=88=ED=95=84=EC=9A=94=ED=95=9C?= =?UTF-8?q?=20Copy=20trait=20=EC=A0=9C=EC=95=BD=20=EC=A0=9C=EA=B1=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- rupring/src/core/mod.rs | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/rupring/src/core/mod.rs b/rupring/src/core/mod.rs index da2a164..4d9d7b3 100644 --- a/rupring/src/core/mod.rs +++ b/rupring/src/core/mod.rs @@ -44,7 +44,7 @@ use crate::IModule; pub async fn run_server( application_properties: application_properties::ApplicationProperties, - root_module: impl IModule + Clone + Copy + Send + Sync + 'static, + root_module: impl IModule + Clone + Send + Sync + 'static, ) -> anyhow::Result<()> { // 1. DI Context Initialize let mut di_context = di::DIContext::new(); @@ -131,6 +131,7 @@ pub async fn run_server( let application_properties = Arc::clone(&application_properties); let running_task_count = Arc::clone(&running_task_count); + let root_module = root_module.clone(); async move { if let Some(timeout_duration) = application_properties.server.request_timeout { @@ -255,7 +256,7 @@ pub async fn run_server( #[cfg(feature = "aws-lambda")] pub async fn run_server_on_aws_lambda( application_properties: application_properties::ApplicationProperties, - root_module: impl IModule + Clone + Copy + Send + Sync + 'static, + root_module: impl IModule + Clone + Send + Sync + 'static, ) -> anyhow::Result<()> { use bootings::aws_lambda::LambdaError; @@ -314,7 +315,7 @@ pub async fn handle_event_on_aws_lambda( mut lambda_request_context: LambdaRequestEvent, application_properties: Arc, di_context: Arc, - root_module: impl IModule + Clone + Copy + Send + Sync + 'static, + root_module: impl IModule + Clone + Send + Sync + 'static, ) -> anyhow::Result<()> { use bootings::aws_lambda::LambdaReponse; @@ -447,7 +448,7 @@ fn default_join_error_handler(error: impl Error) -> Result> async fn process_request( application_properties: Arc, di_context: Arc, - root_module: impl IModule + Clone + Copy + Send + Sync + 'static, + root_module: impl IModule + Clone + Send + Sync + 'static, request: Request, ) -> Result>, Infallible> where