Skip to content
AWS docs0.4

Choosing AWS SDK for Java v2 or AWS SDK for Kotlin

Latest stable Based on AWS release 0.4.0

Both paths support coroutine-based application code, but they reach it differently. Choose by the client model, required AWS feature, and surrounding libraries—not by whether the calling function is marked suspend.

AWS SDK selection map

QuestionJava SDK v2 pathKotlin SDK path
Existing client estateBest when Java SDK v2 clients are already sharedBest when the service is Kotlin SDK-first
Async modelCompletableFuture with suspending adaptersNative suspending operations
DynamoDBStandard and enhanced clients, table schemas, coroutine repositoryNative client, request DSLs, batch executor
S3 transferJava transfer manager and async client extensionsKotlin client object helpers
Framework use in this releaseSpring Boot integrations primarily build Java SDK clientsKtor DynamoDB integration uses Kotlin SDK; other Ktor features may use Java SDK clients or Ktor HTTP
HTTP transportAWS Java SDK HTTP client implementationsSmithy Kotlin CRT/OkHttp engines
Lifecycle concernClose sync/async clients and their owned transportClose clients; close explicitly shared engines separately

Choose Java SDK v2 when interoperability leads

Section titled “Choose Java SDK v2 when interoperability leads”

Use bluetape4k-aws-java when the application already exposes Java SDK clients, needs enhanced DynamoDB APIs, uses the S3 transfer manager, or integrates with Spring Boot auto-configuration in this repository. The library offers three surfaces where supported: direct sync helpers, async CompletableFuture extensions, and suspending extensions over async clients.

The suspending surface does not turn a sync client into non-blocking I/O. Use the async client extensions when coroutine cancellation and non-blocking transport are part of the design.

Choose the Kotlin SDK when the suspend model leads

Section titled “Choose the Kotlin SDK when the suspend model leads”

Use bluetape4k-aws-kotlin when AWS SDK for Kotlin is the primary client layer. Its service clients already expose suspending operations; bluetape4k adds request builders, mapping helpers, batch execution, and higher-level flows such as Kinesis records.

The Kotlin SDK path still has resource ownership. A client-managed HTTP engine closes with the client. An explicitly supplied shared engine does not, so the application must close it after all clients.

Some applications legitimately use both. A Ktor service can use the Kotlin SDK DynamoDB plugin and a Java SDK SQS consumer. Treat that as two explicit runtime stacks:

  • configure region, credentials, endpoint overrides, retries, and timeouts for each;
  • avoid translating models between SDKs in domain code;
  • record which component closes each client and engine;
  • test both emulator paths independently.

If the same service can be implemented entirely on one SDK, the simpler ownership model usually outweighs small syntax differences.