Skip to content

Release preparation for removing Jackson as an external dependency #2598

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jul 16, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
12 changes: 12 additions & 0 deletions .brazil.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"modules": {
"third-party-jackson-core": {
"artifactType": "JAR",
"includes": ["target/aws-sdk-java-third-party-jackson-core-*.jar"]
},
"third-party-jackson-dataformat-cbor": {
"artifactType": "JAR",
"includes": ["target/aws-sdk-java-third-party-jackson-dataformat-cbor-*.jar"]
}
}
}
6 changes: 6 additions & 0 deletions .changes/next-release/feature-AWSSDKforJavav2-9e94920.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"category": "AWS SDK for Java v2",
"contributor": "",
"type": "feature",
"description": "Moved Jackson from an external SDK dependency to an internal dependency: https://aws.amazon.com/blogs/developer/the-aws-sdk-for-java-2-17-removes-its-external-dependency-on-jackson/"
}
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@
# Maven
target/

# JEnv
.java-version

# Shade
**/dependency-reduced-pom.xml

*.pyc
Expand Down
2 changes: 2 additions & 0 deletions NOTICE.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ This software includes third party software subject to the following copyrights:
- PKCS#1 PEM encoded private key parsing and utility functions from oauth.googlecode.com - Copyright 1998-2010 AOL Inc.
- Apache Commons Lang - https://github.com/apache/commons-lang
- Netty Reactive Streams - https://github.com/playframework/netty-reactive-streams
- Jackson-core - https://github.com/FasterXML/jackson-core
- Jackson-dataformat-cbor - https://github.com/FasterXML/jackson-dataformats-binary

The licenses for these third party components are included in LICENSE.txt

Expand Down
4 changes: 2 additions & 2 deletions archetypes/archetype-app-quickstart/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
<parent>
<artifactId>archetypes</artifactId>
<groupId>software.amazon.awssdk</groupId>
<version>2.16.105-SNAPSHOT</version>
<version>2.17.0-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>

Expand Down Expand Up @@ -171,4 +171,4 @@
</plugins>
</build>

</project>
</project>
4 changes: 2 additions & 2 deletions archetypes/archetype-lambda/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
<parent>
<artifactId>archetypes</artifactId>
<groupId>software.amazon.awssdk</groupId>
<version>2.16.105-SNAPSHOT</version>
<version>2.17.0-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>archetype-lambda</artifactId>
Expand Down Expand Up @@ -169,4 +169,4 @@
</plugin>
</plugins>
</build>
</project>
</project>
4 changes: 2 additions & 2 deletions archetypes/archetype-tools/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
<parent>
<artifactId>archetypes</artifactId>
<groupId>software.amazon.awssdk</groupId>
<version>2.16.105-SNAPSHOT</version>
<version>2.17.0-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>

Expand Down Expand Up @@ -59,4 +59,4 @@
</plugins>
</build>

</project>
</project>
4 changes: 2 additions & 2 deletions archetypes/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
<parent>
<artifactId>aws-sdk-java-pom</artifactId>
<groupId>software.amazon.awssdk</groupId>
<version>2.16.105-SNAPSHOT</version>
<version>2.17.0-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>archetypes</artifactId>
Expand All @@ -34,4 +34,4 @@
<description>
Maven Archetypes for applications using Java SDK 2.x
</description>
</project>
</project>
2 changes: 1 addition & 1 deletion aws-sdk-java/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<parent>
<groupId>software.amazon.awssdk</groupId>
<artifactId>aws-sdk-java-pom</artifactId>
<version>2.16.105-SNAPSHOT</version>
<version>2.17.0-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>
<artifactId>aws-sdk-java</artifactId>
Expand Down
7 changes: 1 addition & 6 deletions bom-internal/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
<parent>
<artifactId>aws-sdk-java-pom</artifactId>
<groupId>software.amazon.awssdk</groupId>
<version>2.16.105-SNAPSHOT</version>
<version>2.17.0-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>

Expand Down Expand Up @@ -84,11 +84,6 @@
<artifactId>jackson-datatype-jsr310</artifactId>
<version>${jackson.version}</version>
</dependency>
<dependency>
<groupId>software.amazon.ion</groupId>
<artifactId>ion-java</artifactId>
<version>${ion.java.version}</version>
</dependency>
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
Expand Down
22 changes: 16 additions & 6 deletions bom/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<parent>
<groupId>software.amazon.awssdk</groupId>
<artifactId>aws-sdk-java-pom</artifactId>
<version>2.16.105-SNAPSHOT</version>
<version>2.17.0-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>
<artifactId>bom</artifactId>
Expand Down Expand Up @@ -64,27 +64,37 @@
</dependency>
<dependency>
<groupId>software.amazon.awssdk</groupId>
<artifactId>auth</artifactId>
<artifactId>json-utils</artifactId>
<version>${awsjavasdk.version}</version>
</dependency>
<dependency>
<groupId>software.amazon.awssdk</groupId>
<artifactId>aws-core</artifactId>
<artifactId>third-party-jackson-core</artifactId>
<version>${awsjavasdk.version}</version>
</dependency>
<dependency>
<groupId>software.amazon.awssdk</groupId>
<artifactId>profiles</artifactId>
<artifactId>third-party-jackson-dataformat-cbor</artifactId>
<version>${awsjavasdk.version}</version>
</dependency>
<dependency>
<groupId>software.amazon.awssdk</groupId>
<artifactId>aws-cbor-protocol</artifactId>
<artifactId>auth</artifactId>
<version>${awsjavasdk.version}</version>
</dependency>
<dependency>
<groupId>software.amazon.awssdk</groupId>
<artifactId>aws-core</artifactId>
<version>${awsjavasdk.version}</version>
</dependency>
<dependency>
<groupId>software.amazon.awssdk</groupId>
<artifactId>profiles</artifactId>
<version>${awsjavasdk.version}</version>
</dependency>
<dependency>
<groupId>software.amazon.awssdk</groupId>
<artifactId>aws-ion-protocol</artifactId>
<artifactId>aws-cbor-protocol</artifactId>
<version>${awsjavasdk.version}</version>
</dependency>
<dependency>
Expand Down
13 changes: 1 addition & 12 deletions bundle/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
<parent>
<groupId>software.amazon.awssdk</groupId>
<artifactId>aws-sdk-java-pom</artifactId>
<version>2.16.105-SNAPSHOT</version>
<version>2.17.0-SNAPSHOT</version>
</parent>
<artifactId>bundle</artifactId>
<packaging>jar</packaging>
Expand Down Expand Up @@ -70,31 +70,20 @@
<include>com.fasterxml.jackson.jr:*</include>
<include>io.netty:*</include>
<include>com.typesafe.netty:*</include>
<include>com.fasterxml.jackson.core:*</include>
<include>com.fasterxml.jackson.dataformat:jackson-dataformat-cbor</include>
<include>org.apache.httpcomponents:*</include>
<include>org.reactivestreams:*</include>
<include>org.slf4j:*</include>
<include>commons-codec:commons-codec</include>
<include>software.amazon.ion:ion-java</include>
<include>software.amazon.awssdk:*</include>
<include>software.amazon:*</include>
<include>commons-logging:*</include>
</includes>
</artifactSet>
<relocations>
<relocation>
<pattern>com.fasterxml.jackson</pattern>
<shadedPattern>software.amazon.awssdk.thirdparty.com.fasterxml.jackson</shadedPattern>
</relocation>
<relocation>
<pattern>org.apache</pattern>
<shadedPattern>software.amazon.awssdk.thirdparty.org.apache</shadedPattern>
</relocation>
<relocation>
<pattern>software.amazon.ion</pattern>
<shadedPattern>software.amazon.awssdk.thirdparty.ion</shadedPattern>
</relocation>
<relocation>
<pattern>io.netty</pattern>
<shadedPattern>software.amazon.awssdk.thirdparty.io.netty</shadedPattern>
Expand Down
Empty file added change
Empty file.
2 changes: 1 addition & 1 deletion codegen-lite-maven-plugin/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
<parent>
<groupId>software.amazon.awssdk</groupId>
<artifactId>aws-sdk-java-pom</artifactId>
<version>2.16.105-SNAPSHOT</version>
<version>2.17.0-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>
<artifactId>codegen-lite-maven-plugin</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion codegen-lite/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
<parent>
<groupId>software.amazon.awssdk</groupId>
<artifactId>aws-sdk-java-pom</artifactId>
<version>2.16.105-SNAPSHOT</version>
<version>2.17.0-SNAPSHOT</version>
</parent>
<artifactId>codegen-lite</artifactId>
<name>AWS Java SDK :: Code Generator Lite</name>
Expand Down
2 changes: 1 addition & 1 deletion codegen-maven-plugin/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
<parent>
<groupId>software.amazon.awssdk</groupId>
<artifactId>aws-sdk-java-pom</artifactId>
<version>2.16.105-SNAPSHOT</version>
<version>2.17.0-SNAPSHOT</version>
<relativePath>../pom.xml</relativePath>
</parent>
<artifactId>codegen-maven-plugin</artifactId>
Expand Down
15 changes: 9 additions & 6 deletions codegen/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
<parent>
<groupId>software.amazon.awssdk</groupId>
<artifactId>aws-sdk-java-pom</artifactId>
<version>2.16.105-SNAPSHOT</version>
<version>2.17.0-SNAPSHOT</version>
</parent>
<artifactId>codegen</artifactId>
<name>AWS Java SDK :: Code Generator</name>
Expand Down Expand Up @@ -102,11 +102,6 @@
<artifactId>aws-cbor-protocol</artifactId>
<version>${awsjavasdk.version}</version>
</dependency>
<dependency>
<groupId>software.amazon.awssdk</groupId>
<artifactId>aws-ion-protocol</artifactId>
<version>${awsjavasdk.version}</version>
</dependency>
<dependency>
<groupId>software.amazon.awssdk</groupId>
<artifactId>aws-query-protocol</artifactId>
Expand Down Expand Up @@ -143,6 +138,14 @@
<groupId>com.fasterxml.jackson.jr</groupId>
<artifactId>jackson-jr-stree</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-annotations</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -499,17 +499,12 @@ public Metadata withJsonVersion(String jsonVersion) {
return this;
}

public boolean isIonProtocol() {
return protocol == Protocol.ION;
}

public boolean isCborProtocol() {
return protocol == Protocol.CBOR;
}

public boolean isJsonProtocol() {
return protocol == Protocol.CBOR ||
protocol == Protocol.ION ||
protocol == Protocol.AWS_JSON ||
protocol == Protocol.REST_JSON;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,7 @@ public enum Protocol {
REST_JSON("rest-json"),
CBOR("cbor"),
QUERY("query"),
REST_XML("rest-xml"),
ION("ion");
REST_XML("rest-xml");

private String protocol;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -339,7 +339,6 @@ static ProtocolSpec getProtocolSpecs(PoetExtensions poetExtensions, Intermediate
case AWS_JSON:
case REST_JSON:
case CBOR:
case ION:
return new JsonProtocolSpec(poetExtensions, model);
default:
throw new RuntimeException("Unknown protocol: " + protocol.name());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@
import software.amazon.awssdk.core.http.HttpResponseHandler;
import software.amazon.awssdk.core.protocol.VoidSdkResponse;
import software.amazon.awssdk.protocols.cbor.AwsCborProtocolFactory;
import software.amazon.awssdk.protocols.ion.AwsIonProtocolFactory;
import software.amazon.awssdk.protocols.json.AwsJsonProtocol;
import software.amazon.awssdk.protocols.json.AwsJsonProtocolFactory;
import software.amazon.awssdk.protocols.json.BaseAwsJsonProtocolFactory;
Expand Down Expand Up @@ -119,8 +118,6 @@ private CodeBlock customErrorCodeFieldName() {
private Class<?> protocolFactoryClass() {
if (model.getMetadata().isCborProtocol()) {
return AwsCborProtocolFactory.class;
} else if (model.getMetadata().isIonProtocol()) {
return AwsIonProtocolFactory.class;
} else {
return AwsJsonProtocolFactory.class;
}
Expand Down Expand Up @@ -377,7 +374,6 @@ public Optional<MethodSpec> createErrorResponseHandler() {
private String protocolEnumName(software.amazon.awssdk.codegen.model.intermediate.Protocol protocol) {
switch (protocol) {
case CBOR:
case ION:
case AWS_JSON:
return AWS_JSON.name();
default:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,6 @@ private MarshallerProtocolSpec getProtocolSpecs(software.amazon.awssdk.codegen.m
switch (protocol) {
case REST_JSON:
case CBOR:
case ION:
case AWS_JSON:
return getJsonMarshallerSpec();

Expand Down
2 changes: 1 addition & 1 deletion core/annotations/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
<parent>
<artifactId>core</artifactId>
<groupId>software.amazon.awssdk</groupId>
<version>2.16.105-SNAPSHOT</version>
<version>2.17.0-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>

Expand Down
4 changes: 2 additions & 2 deletions core/arns/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
<parent>
<artifactId>core</artifactId>
<groupId>software.amazon.awssdk</groupId>
<version>2.16.105-SNAPSHOT</version>
<version>2.17.0-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>

Expand Down Expand Up @@ -74,4 +74,4 @@
</plugin>
</plugins>
</build>
</project>
</project>
Loading