I am using spring-boot with Elasticsearch. The project was created using jhipster.
pom.xml contains:
<parent>
<artifactId>spring-boot-starter-parent</artifactId>
<groupId>org.springframework.boot</groupId>
<version>1.4.0.RELEASE</version>
<relativePath/>
</parent>
and
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-data-elasticsearch</artifactId>
</dependency>
In production mode, the following error occurs:
AbstractElasticsearchRepository : failed to load elasticsearch nodes :
org.elasticsearch.client.transport.NoNodeAvailableException: None of
the configured nodes are available: [{#transport#-1}{127.0.0.1}
{localhost/127.0.0.1:9300}]
How can I resolve this error?
In development profile, JHipster uses an embedded Elasticsearch.
In production profile, it tries by default to connect to a local cluster, so either you don't have installed Elasticsearch on your local machine or you
haven't configured the right URL in application-prod.yml
to connect to an existing cluster.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With