英文:
How to specify a newer version of Elasticsearch in spring-boot
问题
如何在spring-boot中为以下库指定一个更新的Elasticsearch版本。这需要作为Gradle依赖项添加:
compile group: 'org.springframework.boot', name: 'spring-boot-starter-data-elasticsearch', version: '2.3.4.RELEASE'
将版本号从7.6.2更改为7.9.1:
compile group: 'org.springframework.boot', name: 'spring-boot-starter-data-elasticsearch', version: '2.3.4.RELEASE'
是否可以在更新的版本下工作?
英文:
How to specify a newer version of Elasticsearch in spring-boot for the following library. This needs to be a gradle dependency
compile group: 'org.springframework.boot', name: 'spring-boot-starter-data-elasticsearch', version: '2.3.4.RELEASE'
say 7.9.1 instead of 7.6.2
Will it work against a newer version?
答案1
得分: 8
你无需将应用程序更新到新版本,如果您的应用程序中未使用一些在7.6.2版本中不可用的本机Elasticsearch库内容。
Spring Data Elasticsearch 4.0.4(由Spring Boot 2.3.4引入)构建于Elasticsearch客户端库的7.6.2版本,但这些客户端库可以与Elasticsearch集群中的7.9.1版本进行通信,就我所知,客户端通信协议没有任何更改。
您将在日志中收到警告:
WARN [main] o.s.d.elasticsearch.support.VersionInfo : Elasticsearch客户端与集群之间的版本不匹配:7.6.2 - 7.9.1
但您可以忽略此警告。
英文:
You don't need to update your application to a newer version if you do not use some native Elasticsearch library stuff in your application which is not available in 7.6.2.
Spring Data Elasticsearch 4.0.4 (pulled in by Spring Boot 2.3.4) is built with the Elasticsearch client libraries in version 7.6.2, but these client libraries can communicate with an Elasticsearch cluster in version 7.9.1, there were no changes in the client communication protocol as far as I know.
You will get a warning in the log:
> WARN [main] o.s.d.elasticsearch.support.VersionInfo : Version mismatch in between Elasticsearch Client and Cluster: 7.6.2 - 7.9.1
but you can ignore that.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论