Description
Describe the bug
When simply including a service, say ec2
in a Gradle build, both the Apache Client and Netty get pulled in as runtime transitive dependencies by default.
This is due to
aws-sdk-java-v2/services/pom.xml
Line 381 in 2f4b44d
aws-sdk-java-v2/services/pom.xml
Line 387 in 2f4b44d
This then automatically gets picked up by the Gradle application plugin and needlessly includes tons of jars in the final package.
Expected behavior
Default to a single client, preferably the plain and lightweight url-connection-client
.
Current behavior
Dozens of additional jars are pulled in by default.
Steps to Reproduce
Create a new build.gradle.kts
file and add the following dependency: implementation("software.amazon.awssdk:ec2:2.17.131")
.
Now run gradle dependencies
and check the runtimeClasspath
section.
Possible Solution
Only depend on url-connection-client
by default.
Context
No response
AWS Java SDK version used
2.17.131
JDK version used
17.0.2
Operating System and version
Win11 x64