Make x-pack core pull transport-nio#32757
Conversation
The security nio transports depend on transport-nio. This commit modifies x-pack core to include the transport-nio jar into the x-pack core module.
|
Pinging @elastic/es-security |
|
@danielmitterdorfer - this will fix the issue you were encountering. |
| shadow 'com.unboundid:unboundid-ldapsdk:3.2.0' | ||
| shadow project(path: ':modules:transport-netty4', configuration: 'runtime') | ||
| shadow(project(path: ':plugins:transport-nio', configuration: 'runtime')) { | ||
| exclude group: "org.elasticsearch", module: "elasticsearch-core" |
There was a problem hiding this comment.
This looks like a bug in esplugin, that core is not being marked as compileOnly in this case (yet it is for depending on the transport-netty4 module). @atorok can you investigate this and open an issue? @tbrooks8 can you add a TODO/comment here that this should not be necessary
x-pack/plugin/core/build.gradle
Outdated
| shadow(project(path: ':plugins:transport-nio', configuration: 'runtime')) { | ||
| // TODO: This should not be necessary if core is compile only | ||
| exclude group: "org.elasticsearch", module: "elasticsearch-core" | ||
| exclude group: "io.netty", module: "netty-buffer" |
There was a problem hiding this comment.
We disable transitive dependencies for anything but org.elasticsearch so these excludes shouldn't be required either.
There was a problem hiding this comment.
transport-nio is under org.elasticsearch, that is why it gets transitive deps.
|
For clarity, the exclude is required to avoid jar hell
The problem is that @rjernst @tbrooks8 I made the changes mentioned above in atorok@4dd5ea3d18e |
|
Thanks for looking at this @atorok. IMO it does not make sense to have core as a |
This is mostly a bit of confusion on my part in the original gradle implementation. I had thought at the time that project dependencies would not show up in generated poms. Note, though, that we do use project substitutions for other reasons, for example within buildSrc, where we cannot depend on these being projects. Personally I have come to like seeing them as full coordinates, and leaving the fact these happen to be another project up to gradle substitutions. |
|
Alright. I made more changes. |
x-pack/plugin/core/build.gradle
Outdated
| shadow 'com.unboundid:unboundid-ldapsdk:3.2.0' | ||
| shadow project(path: ':modules:transport-netty4', configuration: 'runtime') | ||
| shadow(project(path: ':plugins:transport-nio', configuration: 'runtime')) { | ||
| // TODO: This should not be necessary if core is compile only |
There was a problem hiding this comment.
I would expand this comment a bit. Something like:
// TODO: core exclusion should not be necessary, since it is a transitive dep of all plugins
Also, I wonder if this is due to how we add server as a compile dep, but this is shadow here? I wonder if @nik9000's upcoming changes to add bundle will make this better?
…listeners * elastic/master: (58 commits) [ML] Partition-wise maximum scores (elastic#32748) [DOCS] XContentBuilder#bytes method removed, using BytesReference.bytes(docBuilder) (elastic#32771) HLRC: migration get assistance API (elastic#32744) Add a task to run forbiddenapis using cli (elastic#32076) [Kerberos] Add debug log statement for exceptions (elastic#32663) Make x-pack core pull transport-nio (elastic#32757) Painless: Clean Up Whitelist Names (elastic#32791) Cat apis: Fix index creation time to use strict date format (elastic#32510) Clear Job#finished_time when it is opened (elastic#32605) (elastic#32755) Test: Only sniff host metadata for node_selectors (elastic#32750) Update scripted metric docs to use `state` variable (elastic#32695) Painless: Clean up PainlessCast (elastic#32754) [TEST] Certificate NONE not allowed in FIPS JVM (elastic#32753) [ML] Refactor ProcessCtrl into Autodetect and Normalizer builders (elastic#32720) Access build tools resources (elastic#32201) Tests: Disable rolling upgrade tests with system key on fips JVM (elastic#32775) HLRC: Ban LoggingDeprecationHandler (elastic#32756) Fix test reproducability in AbstractBuilderTestCase setup (elastic#32403) Only require java<version>_home env var if needed Tests: Muted ScriptDocValuesDatesTests.testJodaTimeBwc ...
The security nio transports depend on transport-nio. This commit
modifies x-pack core to include the transport-nio jar into the x-pack
core module.