summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Pilato <david@pilato.fr>2017-01-13 14:57:40 +0100
committerDavid Pilato <david@pilato.fr>2017-01-13 14:57:40 +0100
commit812f6e30f577ae1fae8b4d6a356653b8eac110aa (patch)
tree3648d441f36bdd5f7b93c173382455ed91e304d2
parent370ea01149b20b686f7e4f664e1f6633875a5c97 (diff)
Add documentation on remote debugging
For a node which is launched outside the context of Gradle.
-rw-r--r--TESTING.asciidoc19
1 files changed, 18 insertions, 1 deletions
diff --git a/TESTING.asciidoc b/TESTING.asciidoc
index 13f8ca3ca7..83fe27a963 100644
--- a/TESTING.asciidoc
+++ b/TESTING.asciidoc
@@ -474,7 +474,7 @@ Combined (Unit+Integration) coverage:
mvn -Dtests.coverage verify jacoco:report
---------------------------------------------------------------------------
-== Debugging from an IDE
+== Launching and debugging from an IDE
If you want to run elasticsearch from your IDE, the `gradle run` task
supports a remote debugging option:
@@ -483,6 +483,23 @@ supports a remote debugging option:
gradle run --debug-jvm
---------------------------------------------------------------------------
+== Debugging remotely from an IDE
+
+If you want to run elasticsearch and be able to remotely attach the process
+for debugging purposes from your IDE, you need to add the following line in
+`config/jvm.options`:
+
+---------------------------------------------------------------------------
+-Xdebug -Xrunjdwp:server=y,transport=dt_socket,address=4000,suspend=n
+---------------------------------------------------------------------------
+
+Then start elasticsearch with `bin/elasticsearch` as usual.
+
+If you are using IntelliJ, create a new Run/Debug configuration, choose `Remote`
+and define the same port you defined in `config/jvm.options`. Then start the
+remote debug session from IntelliJ.
+
+
== Building with extra plugins
Additional plugins may be built alongside elasticsearch, where their
dependency on elasticsearch will be substituted with the local elasticsearch