Skip to content

Commit

Permalink
chore: Fix aws feature error (#19567)
Browse files Browse the repository at this point in the history
* Use smithy_api_crate

Signed-off-by: Stephen Wakely <fungus.humungus@gmail.com>

* Update cloudwatch_logs test to use SdkBody from types crate

Signed-off-by: Stephen Wakely <fungus.humungus@gmail.com>

---------

Signed-off-by: Stephen Wakely <fungus.humungus@gmail.com>
  • Loading branch information
StephenWakely committed Jan 9, 2024
1 parent f914cf6 commit 2b25a99
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
13 changes: 8 additions & 5 deletions src/aws/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,13 @@ use aws_sigv4::{
use aws_smithy_async::rt::sleep::TokioSleep;
use aws_smithy_runtime::client::http::hyper_014::HyperClientBuilder;
use aws_smithy_runtime_api::client::{
http::{HttpConnector, HttpConnectorFuture, SharedHttpConnector},
http::{
HttpClient, HttpConnector, HttpConnectorFuture, HttpConnectorSettings, SharedHttpConnector,
},
identity::Identity,
orchestrator::{HttpRequest, HttpResponse},
result::SdkError,
runtime_components::RuntimeComponents,
};
use aws_smithy_types::body::SdkBody;
use bytes::Bytes;
Expand Down Expand Up @@ -243,14 +246,14 @@ struct AwsHttpClient<T> {
region: Region,
}

impl<T> aws_smithy_runtime_api::client::http::HttpClient for AwsHttpClient<T>
impl<T> HttpClient for AwsHttpClient<T>
where
T: aws_smithy_runtime_api::client::http::HttpClient,
T: HttpClient,
{
fn http_connector(
&self,
settings: &aws_smithy_runtime_api::client::http::HttpConnectorSettings,
components: &aws_sdk_cloudwatch::config::RuntimeComponents,
settings: &HttpConnectorSettings,
components: &RuntimeComponents,
) -> SharedHttpConnector {
let http_connector = self.http.http_connector(settings, components);

Expand Down
2 changes: 1 addition & 1 deletion src/sinks/aws_cloudwatch_logs/retry.rs
Original file line number Diff line number Diff line change
Expand Up @@ -71,11 +71,11 @@ impl<T: Send + Sync + 'static> RetryLogic for CloudwatchRetryLogic<T> {
#[cfg(test)]
mod test {
use aws_sdk_cloudwatchlogs::operation::put_log_events::PutLogEventsError;
use aws_sdk_s3::primitives::SdkBody;
use aws_smithy_runtime_api::{
client::{orchestrator::HttpResponse, result::SdkError},
http::StatusCode,
};
use aws_smithy_types::body::SdkBody;

use crate::sinks::aws_cloudwatch_logs::{
retry::CloudwatchRetryLogic, service::CloudwatchError,
Expand Down

0 comments on commit 2b25a99

Please sign in to comment.