ES6.X , in IntelliJ IDEA ,from source unable start

conf:
Main class :
org.elasticsearch.bootstrap.Elasticsearch
VM options :
-Xms1g
-Xmx1g
-Dlog4j.shutdownHookEnabled=false
-Dlog4j2.disable.jmx=true
-Des.path.home=/home/sl/02workspace/open/elasticsearch/core
-Des.path.conf=/home/sl/02workspace/open/elasticsearch/core

Run in debug mode, throw exceptions:

[2017-11-21T18:16:13,285][INFO ][o.e.n.Node               ] [] initializing ...
[2017-11-21T18:16:13,455][INFO ][o.e.e.NodeEnvironment    ] [_U7tqWt] using [1] data paths, mounts [[/ (/dev/sda1)]], net usable_space [64.7gb], net total_space [105.1gb], types [ext4]
[2017-11-21T18:16:13,455][INFO ][o.e.e.NodeEnvironment    ] [_U7tqWt] heap size [981.5mb], compressed ordinary object pointers [true]
[2017-11-21T18:16:13,457][INFO ][o.e.n.Node               ] node name [_U7tqWt] derived from node ID [_U7tqWtVRP-qvPm4mWIJXA]; set [node.name] to override
[2017-11-21T18:16:13,457][INFO ][o.e.n.Node               ] version[6.1.0], pid[4390], build[Unknown/Unknown], OS[Linux/4.10.0-37-generic/amd64], JVM[Oracle Corporation/Java HotSpot(TM) 64-Bit Server VM/1.8.0_144/25.144-b01]
[2017-11-21T18:16:13,457][INFO ][o.e.n.Node               ] JVM arguments [-agentlib:jdwp=transport=dt_socket,address=127.0.0.1:42209,suspend=y,server=n, -Xms1g, -Xmx1g, -Dlog4j.shutdownHookEnabled=false, -Dlog4j2.disable.jmx=true, -Des.path.home=/home/sl/02workspace/open/elasticsearch/core, -Des.path.conf=/home/sl/02workspace/open/elasticsearch/core, -Dbuild.snapshot=false, -javaagent:/home/sl/01app/idea/idea-IU-172.3757.52/plugins/Groovy/lib/agent/gragent.jar, -Dfile.encoding=UTF-8]
[2017-11-21T18:16:16,171][INFO ][o.e.p.PluginsService     ] [_U7tqWt] loaded module [aggs-matrix-stats]
[2017-11-21T18:16:16,171][INFO ][o.e.p.PluginsService     ] [_U7tqWt] loaded module [analysis-common]
[2017-11-21T18:16:16,171][INFO ][o.e.p.PluginsService     ] [_U7tqWt] loaded module [ingest-common]
[2017-11-21T18:16:16,171][INFO ][o.e.p.PluginsService     ] [_U7tqWt] loaded module [lang-expression]
[2017-11-21T18:16:16,171][INFO ][o.e.p.PluginsService     ] [_U7tqWt] loaded module [lang-mustache]
[2017-11-21T18:16:16,171][INFO ][o.e.p.PluginsService     ] [_U7tqWt] loaded module [lang-painless]
[2017-11-21T18:16:16,172][INFO ][o.e.p.PluginsService     ] [_U7tqWt] loaded module [mapper-extras]
[2017-11-21T18:16:16,172][INFO ][o.e.p.PluginsService     ] [_U7tqWt] loaded module [parent-join]
[2017-11-21T18:16:16,172][INFO ][o.e.p.PluginsService     ] [_U7tqWt] loaded module [percolator]
[2017-11-21T18:16:16,172][INFO ][o.e.p.PluginsService     ] [_U7tqWt] loaded module [reindex]
[2017-11-21T18:16:16,172][INFO ][o.e.p.PluginsService     ] [_U7tqWt] loaded module [repository-url]
[2017-11-21T18:16:16,172][INFO ][o.e.p.PluginsService     ] [_U7tqWt] loaded module [transport-netty4]
[2017-11-21T18:16:16,172][INFO ][o.e.p.PluginsService     ] [_U7tqWt] loaded module [tribe]
[2017-11-21T18:16:16,173][INFO ][o.e.p.PluginsService     ] [_U7tqWt] no plugins loaded
[2017-11-21T18:16:16,358][INFO ][i.n.u.i.PlatformDependent] Your platform does not provide complete low-level API for accessing direct buffers reliably. Unless explicitly requested, heap buffer will always be preferred to avoid potential system instability.
[2017-11-21T18:16:18,330][INFO ][o.e.d.DiscoveryModule    ] [_U7tqWt] using discovery type [zen]
[2017-11-21T18:16:40,757][WARN ][o.e.b.ElasticsearchUncaughtExceptionHandler] [] uncaught exception in thread [main]
org.elasticsearch.bootstrap.StartupException: org.elasticsearch.common.inject.CreationException: Guice creation errors:

1) No implementation for org.elasticsearch.cluster.ClusterInfoService was bound.
  while locating org.elasticsearch.cluster.ClusterInfoService
    for parameter 6 at org.elasticsearch.action.admin.cluster.allocation.TransportClusterAllocationExplainAction.<init>(Unknown Source)
  at _unknown_
2) An exception was caught and reported. Message: null
  at _unknown_
3) No implementation for org.elasticsearch.transport.Transport was bound.
  at _unknown_
........
125 errors
	at org.elasticsearch.common.inject.internal.Errors.throwCreationExceptionIfErrorsExist(Errors.java:361) ~[main/:?]
	at org.elasticsearch.common.inject.InjectorBuilder.initializeStatically(InjectorBuilder.java:137) ~[main/:?]
	at org.elasticsearch.common.inject.InjectorBuilder.build(InjectorBuilder.java:93) ~[main/:?]
	at org.elasticsearch.common.inject.Guice.createInjector(Guice.java:96) ~[main/:?]
 ....

who can help me ? thanks

Just run gradle run instead of trying to start from the IDE?

By the way you said ,it can run.
But here ,I want to debugg , running in the IDE ,so I can easily change the value of some variables test something . In the previous ES 5.X , it's no problem . I don't know why 6.x can not .

now, I just debugging by IDE remote debug -- slightly inconvenient.

Maybe some wrong my development environment...

now, I just debugging by IDE remote debug -- slightly inconvenient.

That’s the way to go.

But what are you trying to debug? Elasticsearch? A plugin you wrote? Your application?

Habits to keep the latest code, ES update more frequently ,each update must be repackaged ,more time-consuming.

and , dev plugin , just put code in core/src , can easily develop,debug,modify... the plugin code.

so ,remote debug -- time consuming , on my compute rebuilding a tar want about 10 min.

Then you need to run gradle run --debug-jvm and connect your IDE debugger to it.

So you are writing a plugin? Sorry it's unclear to me.

If you are doing so, I'd run integration tests using the elasticsearch test framework.
Then you can attach elasticsearch code source to your project and add breakpoints in it (or better in your code).

BTW, working on a non stable version of elasticsearch (like master branch) does not look to me as the best thing to do.
I'm only doing so iif the latest version does not contain a patch I absolutely need. In which case, I'm building my local version which I'm using in integration tests.

My 2 cents.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.