|
10 | 10 | apply plugin: 'elasticsearch.build'
|
11 | 11 | apply plugin: 'elasticsearch.publish'
|
12 | 12 |
|
13 |
| -configurations { |
14 |
| - // we do not want to expose a version conflict in transitive dependencies by |
15 |
| - // bringing in different versions of hamcrest and hamcrest-core. |
16 |
| - // Therefore we exclude transitive deps on hamcrest-core here as we have a direct |
17 |
| - // dependency on a newer version. |
18 |
| - runtimeElements { |
19 |
| - exclude group: 'org.hamcrest', module: 'hamcrest-core' |
20 |
| - } |
21 |
| -} |
22 | 13 | dependencies {
|
23 | 14 | api project(":client:rest")
|
24 | 15 | api project(':modules:transport-netty4')
|
25 | 16 | api project(':libs:ssl-config')
|
26 | 17 | api project(":server")
|
27 | 18 | api project(":libs:cli")
|
28 | 19 | api project(":libs:entitlement:bridge")
|
29 |
| - api "com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}" |
30 |
| - api("junit:junit:${versions.junit}") { |
31 |
| -// exclude group: 'org.hamcrest' |
| 20 | + api ("com.carrotsearch.randomizedtesting:randomizedtesting-runner:${versions.randomizedrunner}") { |
| 21 | + exclude group: "junit", module: "junit" |
32 | 22 | }
|
| 23 | + |
| 24 | + // we do not want to expose a version conflict in transitive dependencies by |
| 25 | + // bringing in different versions of dependencies. |
| 26 | + // Therefore we exclude mismatches in our transitive dependencies explicitly. |
| 27 | + // This also avoids jarHell issues with different hamcrest related dependencies |
| 28 | + // like hamcrest and hamcrest-core |
33 | 29 | api "org.hamcrest:hamcrest:${versions.hamcrest}"
|
| 30 | + api("junit:junit:${versions.junit}") { |
| 31 | + exclude group: 'org.hamcrest', module: 'hamcrest-core' |
| 32 | + } |
34 | 33 | api("org.apache.lucene:lucene-test-framework:${versions.lucene}") {
|
35 |
| -// exclude group: 'org.hamcrest' |
| 34 | + exclude group: "junit", module: "junit" |
| 35 | + exclude group: 'com.carrotsearch.randomizedtesting', module: 'randomizedtesting-runner' |
36 | 36 | }
|
37 | 37 | api "org.apache.lucene:lucene-codecs:${versions.lucene}"
|
38 | 38 | api "commons-logging:commons-logging:${versions.commonslogging}"
|
|
0 commit comments