Dependency version changes for ES upgrade 5.5 to 6.5

We are upgrading ES from 5.5.1 to 6.5.4. We need to use the correct dependencies to support ES 6.5. Currently for 5.5 we have dependencies mentioned in build.gradle like below.

dependencies {
compile group: 'org.elasticsearch', name : 'elasticsearch', version: '5.5.1'
compile group: 'commons-codec', name: 'commons-codec', version: '1.10'
compile group: 'com.google.guava', name: 'guava', version: '21.0'
compile group: 'commons-net', name:'commons-net', version: '3.5+'
compile group: 'org.apache.logging.log4j', name: 'log4j-api', version: '2.7'
compile group: 'org.apache.httpcomponents', name: 'httpclient', version: '4.2.3'
testCompile group: 'org.jmockit', name: 'jmockit', version: '1.9'
testCompile group: 'junit', name: 'junit', version: '4.12'
}

task copyToLib(type: Copy) {
into "$buildDir/libs"
from configurations.runtime
include 'guava-21.0.jar'
}

Can you please tell me the relevant dependency versions for ES 6.5 where I put '?' sign :slight_smile:

dependencies {
compile group: 'org.elasticsearch', name : 'elasticsearch', version: '6.5.4'
compile group: 'commons-codec', name: 'commons-codec', version: '?'
compile group: 'com.google.guava', name: 'guava', version: '?'
compile group: 'commons-net', name:'commons-net', version: '?'
compile group: 'org.apache.logging.log4j', name: 'log4j-api', version: '?'
compile group: 'org.apache.httpcomponents', name: 'httpclient', version: '?'
testCompile group: 'org.jmockit', name: 'jmockit', version: '?'
testCompile group: 'junit', name: 'junit', version: '?'
}

task copyToLib(type: Copy) {
into "$buildDir/libs"
from configurations.runtime
include '?'
}

And last but not least, if we dont change the versions of other dependencies and we continue to use the same versions which were used for ES 5.5.1 will it be problem?

As you are using a dependency manager, there is no need to declare other libs.

dependencies {
    compile 'org.elasticsearch.client:elasticsearch-rest-high-level-client:6.5.4'
}

If you are using the Rest client (recommended).

Not sure about the dependency manager, have to check.

Yes we are using rest client. So you are saying if we have one dependency mentioned
elasticsearch-rest-high-level-client:6.5.4 then we don't need to mention other dependencies like log4j, guava etc separately?

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.