我打算修復Elastic Search開源項目上的錯誤。我分叉它並克隆分叉副本。然後我將它作爲Maven項目導入到Eclipse中,然後創建Maven。到現在爲止還挺好。 我打開ElasticSearchF.java文件並試圖將其作爲Java應用程序運行(這是按照http://www.lindstromhenrik.com/debugging-elasticsearch-in-eclipse/中寫的方向)。彈性搜索錯誤
但是我得到一個錯誤,說path.home沒有爲ElasticSearch設置,並拋出一個錯誤說IllegalStateException。
我的問題是
- 爲什麼擺在首位來了這個錯誤。
- 正如我所說的,我想修復ElasticSearch項目中的錯誤。這是爲我的目標設置環境的正確方法嗎?或者,我應該讓客戶端將請求發送到ElasticSearch服務器,然後在Elastic Search源代碼中設置調試點。如何實現這一目標?
感謝您的耐心等待。
更新: 我沒有添加虛擬機參數,如其中一個答覆者所述。
然後它拋出不同的錯誤和線索,爲什麼它拋出。
java.io.IOException: Resource not found: "org/joda/time/tz/data/ZoneInfoMap" ClassLoader: [email protected]
at org.joda.time.tz.ZoneInfoProvider.openResource(ZoneInfoProvider.java:210)
at org.joda.time.tz.ZoneInfoProvider.<init>(ZoneInfoProvider.java:127)
at org.joda.time.tz.ZoneInfoProvider.<init>(ZoneInfoProvider.java:86)
at org.joda.time.DateTimeZone.getDefaultProvider(DateTimeZone.java:514)
at org.joda.time.DateTimeZone.getProvider(DateTimeZone.java:413)
at org.joda.time.DateTimeZone.forID(DateTimeZone.java:216)
at org.joda.time.DateTimeZone.getDefault(DateTimeZone.java:151)
at org.joda.time.chrono.ISOChronology.getInstance(ISOChronology.java:79)
at org.joda.time.DateTimeUtils.getChronology(DateTimeUtils.java:266)
at org.joda.time.format.DateTimeFormatter.selectChronology(DateTimeFormatter.java:968)
at org.joda.time.format.DateTimeFormatter.printTo(DateTimeFormatter.java:672)
at org.joda.time.format.DateTimeFormatter.printTo(DateTimeFormatter.java:560)
at org.joda.time.format.DateTimeFormatter.print(DateTimeFormatter.java:644)
at org.elasticsearch.Build.<clinit>(Build.java:53)
at org.elasticsearch.node.Node.<init>(Node.java:138)
at org.elasticsearch.node.NodeBuilder.build(NodeBuilder.java:157)
at org.elasticsearch.bootstrap.Bootstrap.setup(Bootstrap.java:177)
at org.elasticsearch.bootstrap.Bootstrap.main(Bootstrap.java:278)
at 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 with name 'Lucene50' does not exist. You need to add the corresponding JAR file supporting this SPI to your classpath. The current classpath supports the following names: [es090, completion090, XBloomFilter]]
你看這個? https://github.com/elastic/elasticsearch/blob/master/CONTRIBUTING.md#contributing-code-and-documentation-changes –
@ user4654你找出解決辦法了嗎? – keety
@ user4654你找到了解決辦法嗎?我也面臨着同樣的錯誤 –