Skip to content

Commit

Permalink
fix: default to PickFirstLoadBalancerProvider (GoogleCloudPlatform#2063)
Browse files Browse the repository at this point in the history
The services/META-INF/io.grpc.LoadBalancerProvider file included by
default in the jar with dependencies did not correspond with the
default pick_first policy of AutoConfiguredLoadBalancerFactory.

Fixes GoogleCloudPlatform#2061

Co-authored-by: Les Vogel <lesv@users.noreply.github.com>
  • Loading branch information
olavloite and lesv committed Feb 15, 2020
1 parent b9a5132 commit c2188a9
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 3 deletions.
27 changes: 27 additions & 0 deletions spanner/cloud-client/assembly-descriptor.xml
@@ -0,0 +1,27 @@
<assembly xmlns="http://maven.apache.org/ASSEMBLY/2.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/ASSEMBLY/2.0.0 http://maven.apache.org/xsd/assembly-2.0.0.xsd">
<id>jar-with-dependencies</id>
<formats>
<format>jar</format>
</formats>
<includeBaseDirectory>false</includeBaseDirectory>
<dependencySets>
<dependencySet>
<outputDirectory>/</outputDirectory>
<useProjectArtifact>false</useProjectArtifact>
<unpack>true</unpack>
<unpackOptions>
<excludes>
<exclude>io.grpc.LoadBalancerProvider</exclude>
</excludes>
</unpackOptions>
</dependencySet>
</dependencySets>
<fileSets>
<fileSet>
<directory>${project.build.outputDirectory}</directory>
<outputDirectory>.</outputDirectory>
</fileSet>
</fileSets>
</assembly>
6 changes: 3 additions & 3 deletions spanner/cloud-client/pom.xml
Expand Up @@ -146,9 +146,9 @@ limitations under the License.
<artifactId>maven-assembly-plugin</artifactId>
<version>3.2.0</version>
<configuration>
<descriptorRefs>
<descriptorRef>jar-with-dependencies</descriptorRef>
</descriptorRefs>
<descriptors>
<descriptor>assembly-descriptor.xml</descriptor>
</descriptors>
<archive>
<manifest>
<mainClass>com.example.spanner.SpannerSample</mainClass>
Expand Down
@@ -0,0 +1 @@
io.grpc.internal.PickFirstLoadBalancerProvider

0 comments on commit c2188a9

Please sign in to comment.