Skip to content

Commit

Permalink
2.x: Upgrade grpc-java to 1.57.1 and remove repackaging of io.grpc (#…
Browse files Browse the repository at this point in the history
…7300)

* Upgrade grpc-java to 1.57.1 and no longer repackage
* Use grpc-bom to manage version
  • Loading branch information
barchetta authored Aug 3, 2023
1 parent 7070788 commit 8463a20
Show file tree
Hide file tree
Showing 28 changed files with 28 additions and 662 deletions.
4 changes: 2 additions & 2 deletions config/etcd/src/main/java/module-info.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2017, 2020 Oracle and/or its affiliates.
* Copyright (c) 2017, 2023 Oracle and/or its affiliates.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand All @@ -26,11 +26,11 @@
requires etcd4j;
requires grpc.protobuf;
requires grpc.stub;
requires grpc.api;
requires com.google.protobuf;
requires com.google.common;
requires io.helidon.common;
requires io.helidon.common.media.type;
requires io.grpc;

exports io.helidon.config.etcd;

Expand Down
78 changes: 8 additions & 70 deletions dependencies/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
<version.lib.graphql-java>18.6</version.lib.graphql-java>
<version.lib.graphql-java.extended.scalars>18.3</version.lib.graphql-java.extended.scalars>
<version.lib.gson>2.9.0</version.lib.gson>
<version.lib.grpc>1.56.0</version.lib.grpc>
<version.lib.grpc>1.57.1</version.lib.grpc>
<version.lib.guava>32.0.1-jre</version.lib.guava>
<version.lib.h2>1.4.200</version.lib.h2>
<version.lib.hamcrest>1.3</version.lib.hamcrest>
Expand Down Expand Up @@ -374,75 +374,6 @@
<artifactId>etcd4j</artifactId>
<version>${version.lib.etcd4j}</version>
</dependency>
<dependency>
<groupId>io.grpc</groupId>
<artifactId>grpc-core</artifactId>
<version>${version.lib.grpc}</version>
<exclusions>
<exclusion>
<!-- Used for compilation of "their" sources -->
<groupId>com.google.code.findbugs</groupId>
<artifactId>jsr305</artifactId>
</exclusion>
<exclusion>
<!-- Used for compilation of "their" sources -->
<groupId>com.google.errorprone</groupId>
<artifactId>error_prone_annotations</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>io.grpc</groupId>
<artifactId>grpc-api</artifactId>
<version>${version.lib.grpc}</version>
<exclusions>
<exclusion>
<!-- Used for compilation of "their" sources -->
<groupId>org.codehaus.mojo</groupId>
<artifactId>animal-sniffer-annotations</artifactId>
</exclusion>
<exclusion>
<!-- Used for compilation of "their" sources -->
<groupId>com.google.errorprone</groupId>
<artifactId>error_prone_annotations</artifactId>
</exclusion>
<exclusion>
<!-- Used for compilation of "their" sources -->
<groupId>com.google.code.findbugs</groupId>
<artifactId>jsr305</artifactId>
</exclusion>
<exclusion>
<!-- Used for compilation of "their" sources -->
<groupId>com.google.j2objc</groupId>
<artifactId>j2objc-annotations</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>io.grpc</groupId>
<artifactId>grpc-context</artifactId>
<version>${version.lib.grpc}</version>
</dependency>
<dependency>
<groupId>io.grpc</groupId>
<artifactId>grpc-protobuf</artifactId>
<version>${version.lib.grpc}</version>
</dependency>
<dependency>
<groupId>io.grpc</groupId>
<artifactId>grpc-stub</artifactId>
<version>${version.lib.grpc}</version>
</dependency>
<dependency>
<groupId>io.grpc</groupId>
<artifactId>grpc-services</artifactId>
<version>${version.lib.grpc}</version>
</dependency>
<dependency>
<groupId>io.grpc</groupId>
<artifactId>grpc-netty</artifactId>
<version>${version.lib.grpc}</version>
</dependency>

<!-- Dependency convergence. Should align with version used by io.grpc -->
<dependency>
Expand Down Expand Up @@ -1446,6 +1377,13 @@

<!-- imported boms -->
<!-- Force upgrade. Used by grpc -->
<dependency>
<groupId>io.grpc</groupId>
<artifactId>grpc-bom</artifactId>
<version>${version.lib.grpc}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
<dependency>
<groupId>com.google.protobuf</groupId>
<artifactId>protobuf-bom</artifactId>
Expand Down
8 changes: 8 additions & 0 deletions grpc/core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,10 @@
<groupId>io.grpc</groupId>
<artifactId>grpc-core</artifactId>
</exclusion>
<exclusion>
<groupId>com.google.j2objc</groupId>
<artifactId>j2objc-annotations</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
Expand All @@ -81,6 +85,10 @@
<groupId>io.grpc</groupId>
<artifactId>grpc-api</artifactId>
</exclusion>
<exclusion>
<groupId>com.google.j2objc</groupId>
<artifactId>j2objc-annotations</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
Expand Down
4 changes: 2 additions & 2 deletions grpc/core/src/main/java/module-info.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2019, 2020 Oracle and/or its affiliates.
* Copyright (c) 2019, 2023 Oracle and/or its affiliates.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -33,9 +33,9 @@

requires grpc.netty;
requires transitive grpc.protobuf;
requires transitive grpc.api;
requires grpc.protobuf.lite;
requires transitive grpc.stub;
requires transitive io.grpc;
requires io.netty.handler;
requires io.netty.transport;
requires transitive com.google.protobuf;
Expand Down
79 changes: 2 additions & 77 deletions grpc/io.grpc/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@
</parent>

<artifactId>io.grpc</artifactId>
<name>Helidon grpc-java Repackaged</name>
<description>A Java modules compatible re-packaging of grpc-java</description>
<name>Helidon grpc-java Bundle</name>
<description>Bundle of grpc dependencies provided for backwards compatibility</description>

<dependencies>
<dependency>
Expand All @@ -41,80 +41,5 @@
<groupId>io.grpc</groupId>
<artifactId>grpc-core</artifactId>
</dependency>
<dependency>
<groupId>io.grpc</groupId>
<artifactId>grpc-context</artifactId>
</dependency>

<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
<exclusions>
<exclusion>
<artifactId>jsr305</artifactId>
<groupId>com.google.code.findbugs</groupId>
</exclusion>
<exclusion>
<artifactId>error_prone_annotations</artifactId>
<groupId>com.google.errorprone</groupId>
</exclusion>
<exclusion>
<artifactId>j2objc-annotations</artifactId>
<groupId>com.google.j2objc</groupId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>com.google.code.gson</groupId>
<artifactId>gson</artifactId>
</dependency>
<dependency>
<groupId>io.perfmark</groupId>
<artifactId>perfmark-api</artifactId>
</dependency>
</dependencies>

<build>
<plugins>
<!-- create the base JAR removing all of the dummy classes -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<excludes>
<exclude>io/grpc/**/*.class</exclude>
</excludes>
</configuration>
</plugin>

<!-- create the shaded JAR -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<executions>
<execution>
<id>shade</id>
<phase>package</phase>
<goals>
<goal>shade</goal>
</goals>
<configuration>
<shadedArtifactAttached>false</shadedArtifactAttached>
<createDependencyReducedPom>true</createDependencyReducedPom>
<createSourcesJar>true</createSourcesJar>
<promoteTransitiveDependencies>true</promoteTransitiveDependencies>
<artifactSet>
<includes>
<include>io.grpc:*</include>
<include>com.google.instrumentation:instrumentation-api</include>
<include>io.opencensus:opencensus-api</include>
<include>io.opencensus:opencensus-contrib-grpc-metrics</include>
</includes>
</artifactSet>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
27 changes: 0 additions & 27 deletions grpc/io.grpc/src/main/java/io/grpc/LoadBalancerProvider.java

This file was deleted.

27 changes: 0 additions & 27 deletions grpc/io.grpc/src/main/java/io/grpc/ManagedChannelProvider.java

This file was deleted.

27 changes: 0 additions & 27 deletions grpc/io.grpc/src/main/java/io/grpc/NameResolverProvider.java

This file was deleted.

27 changes: 0 additions & 27 deletions grpc/io.grpc/src/main/java/io/grpc/ServerProvider.java

This file was deleted.

26 changes: 0 additions & 26 deletions grpc/io.grpc/src/main/java/io/grpc/inprocess/DummyClass.java

This file was deleted.

Loading

0 comments on commit 8463a20

Please sign in to comment.