springboot集成elasticsearch时报错NoNodeAvailableException[None of the configured nodes are available: [{#
我在集成elasticsearch在idea的控制台里出现如下报错,但是我的配置是没有问题的
NoNodeAvailableException[None of the configured nodes are available: [{#transport#-1}{c86bxOiITCqF-lqJc2C-XQ}{localhost}{127.0.0.1:9300}]
]
at org.elasticsearch.client.transport.TransportClientNodesService.ensureNodesAreAvailable(TransportClientNodesService.java:347)
at org.elasticsearch.client.transport.TransportClientNodesService.execute(TransportClientNodesService.java:245)
at org.elasticsearch.client.transport.TransportProxyClient.execute(TransportProxyClient.java:59)
at org.elasticsearch.client.transport.TransportClient.doExecute(TransportClient.java:366)
at org.elasticsearch.client.support.AbstractClient.execute(AbstractClient.java:408)
at org.elasticsearch.action.ActionRequestBuilder.execute(ActionRequestBuilder.java:80)
at org.elasticsearch.action.ActionRequestBuilder.execute(ActionRequestBuilder.java:54)
然后我在elasticsearch的控制台,看见如下错误
原来是我的elasticsearch是2.4.4版本太低了,我就换成5.2.0版本,问题解决