Skip to content

Commit

Permalink
chore: Use CRT http engine. (#51021)
Browse files Browse the repository at this point in the history
Co-authored-by: Octavia Squidington III <[email protected]>
  • Loading branch information
tryangul and octavia-squidington-iii authored Jan 9, 2025
1 parent 5dfb632 commit e7b8fc4
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
3 changes: 2 additions & 1 deletion airbyte-cdk/bulk/toolkits/load-s3/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,6 @@ dependencies {
api project(':airbyte-cdk:bulk:toolkits:bulk-cdk-toolkit-load-object-storage')

testFixturesApi(testFixtures(project(":airbyte-cdk:bulk:toolkits:bulk-cdk-toolkit-load-object-storage")))
implementation("aws.sdk.kotlin:s3:1.3.94")
implementation("aws.sdk.kotlin:s3:1.3.98")
implementation("aws.smithy.kotlin:http-client-engine-crt:1.3.31")
}
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ import aws.sdk.kotlin.services.s3.model.PutObjectRequest
import aws.smithy.kotlin.runtime.auth.awscredentials.CredentialsProvider
import aws.smithy.kotlin.runtime.content.ByteStream
import aws.smithy.kotlin.runtime.content.toInputStream
import aws.smithy.kotlin.runtime.http.engine.crt.CrtHttpEngine
import aws.smithy.kotlin.runtime.net.url.Url
import edu.umd.cs.findbugs.annotations.SuppressFBWarnings
import io.airbyte.cdk.load.command.aws.AWSAccessKeyConfigurationProvider
Expand Down Expand Up @@ -244,6 +245,10 @@ class S3ClientFactory(
Url.parse(it)
} else null
}

// Fix for connection reset issue:
// https://github.com/awslabs/aws-sdk-kotlin/issues/1214#issuecomment-2464831817
httpClient(CrtHttpEngine)
}

return S3Client(
Expand Down

0 comments on commit e7b8fc4

Please sign in to comment.