maven - Elastic Search error -
i 'm intending fix bugs on elastic search open-source project. forked , cloned forked copy . imported maven project on eclipse , did maven build . far good. opened elasticsearchf.java file , tried run java application.(this per directions written in http://www.lindstromhenrik.com/debugging-elasticsearch-in-eclipse/).
but error saying path.home not set elasticsearch , throws error saying illegalstateexception.
my question
- why error coming in first place.
- as said , want fix bugs in elasticsearch project.is right way set-up environment goal? or should have client send requests elasticsearch server , set-up debug points in elastic search source code. how achieve this?
thanks patience.
update: did add vm argument mentioned 1 of answerers.
then throws different errors , clue-less why throwing that.
java.io.ioexception: resource not found: "org/joda/time/tz/data/zoneinfomap" classloader: sun.misc.launcher$appclassloader@29578426 @ org.joda.time.tz.zoneinfoprovider.openresource(zoneinfoprovider.java:210) @ org.joda.time.tz.zoneinfoprovider.<init>(zoneinfoprovider.java:127) @ org.joda.time.tz.zoneinfoprovider.<init>(zoneinfoprovider.java:86) @ org.joda.time.datetimezone.getdefaultprovider(datetimezone.java:514) @ org.joda.time.datetimezone.getprovider(datetimezone.java:413) @ org.joda.time.datetimezone.forid(datetimezone.java:216) @ org.joda.time.datetimezone.getdefault(datetimezone.java:151) @ org.joda.time.chrono.isochronology.getinstance(isochronology.java:79) @ org.joda.time.datetimeutils.getchronology(datetimeutils.java:266) @ org.joda.time.format.datetimeformatter.selectchronology(datetimeformatter.java:968) @ org.joda.time.format.datetimeformatter.printto(datetimeformatter.java:672) @ org.joda.time.format.datetimeformatter.printto(datetimeformatter.java:560) @ org.joda.time.format.datetimeformatter.print(datetimeformatter.java:644) @ org.elasticsearch.build.<clinit>(build.java:53) @ org.elasticsearch.node.node.<init>(node.java:138) @ org.elasticsearch.node.nodebuilder.build(nodebuilder.java:157) @ org.elasticsearch.bootstrap.bootstrap.setup(bootstrap.java:177) @ org.elasticsearch.bootstrap.bootstrap.main(bootstrap.java:278) @ org.elasticsearch.bootstrap.elasticsearchf.main(elasticsearchf.java:30) [2015-06-16 18:51:36,892][info ][node ] [kismet deadly] version[2.0.0-snapshot], pid[2516], build[9b833fd/2015-06-15t03:38:40z] [2015-06-16 18:51:36,892][info ][node ] [kismet deadly] initializing ... [2015-06-16 18:51:36,899][info ][plugins ] [kismet deadly] loaded [], sites [] {2.0.0-snapshot}: initialization failed ... - exceptionininitializererror illegalargumentexception[an spi class of type org.apache.lucene.codecs.postingsformat name 'lucene50' not exist. need add corresponding jar file supporting spi classpath. current classpath supports following names: [es090, completion090, xbloomfilter]]
i got developer community in https://github.com/elastic/elasticsearch/issues/12737 , able debug it.
procedure in short :
1) search file elasticsearch.java/elasticsearchf.java inside package org.elasticsearch.bootstrap .
2) right click -> run configurations...
3) in window pops , click "arguments" tab , under "program arguments:" section give value start , under "vm arguments:" section give value as
-des.path.home={path elasticsearch code base root folder}/core -des.security.manager.enabled=false
4) click "apply" , click "run".
it runs now. check , go localhost:9200 , message like
{ "name" : "raza", "cluster_name" : "elasticsearch", "version" : { "number" : "2.0.0-beta1", "build_hash" : "${buildnumber}", "build_timestamp" : "na", "build_snapshot" : true, "lucene_version" : "5.2.1" }, "tagline" : "you know, search" }
for more info on arguments see : https://github.com/elastic/elasticsearch/commit/2b9ef26006c0e4608110164480b8127dffb9d6ad
Comments
Post a Comment