alexcojocaru / elasticsearch-maven-plugin

A Maven plugin to run a single node Elasticsearch cluster during the integration test phase of a build
Apache License 2.0
87 stars 47 forks source link

Elasticsearch version 2 unable to start instance #61

Closed manjirinamjoshi closed 6 years ago

manjirinamjoshi commented 6 years ago

Hello,

Unfortunately, our prod env is running elastic search version 2.4.1. So, I am trying to use version 2 of this plugin.

But, when I try - mvn elasticsearch:start it doesnt seem to load the Init script and also, doesnt seem to start the elasticsearch instance.

IRV-MNAMJOSH-7D:mtd mnamjoshi$ mvn elasticsearch:start [INFO] Scanning for projects... [INFO]
[INFO] ------------------------------------------------------------------------ [INFO] Building java-metadata 0.0.2-SNAPSHOT [INFO] ------------------------------------------------------------------------ [INFO] [INFO] --- elasticsearch-maven-plugin:2.0:start (default-cli) @ java-metadata --- log4j:WARN No appenders could be found for logger (org.elasticsearch.node). log4j:WARN Please initialize the log4j system properly. log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info. [INFO] ------------------------------------------------------------------------ [INFO] BUILD SUCCESS [INFO] ------------------------------------------------------------------------ [INFO] Total time: 2.882 s [INFO] Finished at: 2018-05-24T22:26:05-07:00 [INFO] Final Memory: 22M/309M [INFO] ------------------------------------------------------------------------ IRV-MNAMJOSH-7D:mtd mnamjoshi

Following is the snippet from my pom.xml -

com.github.alexcojocaru elasticsearch-maven-plugin 2.0 2.0.0 mtd 9300 9200 9300 true src/test/resources/elasticsearch/Init.script org.slf4j slf4j-log4j12 1.7.25 start-elasticsearch pre-integration-test runforked stop-elasticsearch post-integration-test stop

Thank you

Sincerely, Manjiri

alexcojocaru commented 6 years ago

Sorry about the delay in replying, I thought I have done that already. It's not working because you are using the v5+ configuration. Here is the documentation for the 2.x branch: https://github.com/alexcojocaru/elasticsearch-maven-plugin/tree/elasticsearch-2.x, check out the plugin config and goals (eg. load, run).

manjirinamjoshi commented 6 years ago

Thank you for the pointer, I will try it out.

alexcojocaru commented 6 years ago

I am going to close this issue; feel free to reopen if the doc is wrong or not clear.