Skip to content

X-Pack Transport Client POM does not include all dependencies #31946

Closed
@tvernum

Description

@tvernum

In 6.2 and earlier, the x-pack-transport POM had a dependency on x-pack-api which pulled in 3rd party dependencies such as the UnboundId LDAP SDK and Bouncy Castle (for reading TLS keys)

The (abbreviated) dependency tree was:

+- org.elasticsearch.client:x-pack-transport:jar:6.2.4:compile
|  +- org.elasticsearch.plugin:x-pack-api:jar:6.2.4:compile
|  |  +- com.unboundid:unboundid-ldapsdk:jar:3.2.0:compile
|  |  +- org.bouncycastle:bcprov-jdk15on:jar:1.58:compile
|  |  +- org.bouncycastle:bcpkix-jdk15on:jar:1.58:compile

Since 6.3 the x-pack-api POM no longer exists, and x-pack-transport simply depends on x-pack-core which does not include any 3rd party dependencies.
As far as I can tell from grepping, none of our generated POM files include a dependency for the ldapsdk (nor, I assume, bouncy castle).

This means that the published dependency in our docs is insufficient

 <dependencies>
      <!-- add the x-pack jar as a dependency -->
      <dependency>
         <groupId>org.elasticsearch.client</groupId>
         <artifactId>x-pack-transport</artifactId>
              <version>{version}</version>
      </dependency>
      ...
   </dependencies>

There is a qa test for transport client with ML, but because it uses gradle with local project dependencies, it pulls in the transitive dependency list from x-pack-core including the LDAP sdk, etc

+--- project :x-pack:plugin:core
|    [ snip ]
|    +--- com.unboundid:unboundid-ldapsdk:3.2.0
|    +--- org.bouncycastle:bcprov-jdk15on:1.58
|    +--- org.bouncycastle:bcpkix-jdk15on:1.58

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions