I'm trying to put the vertx app inside the docker container and want to use Eclipse to remote debug the app when needed.
First question, I'm not fully understand this paragraph in the
vertx core manual. It would be nice if there will be a example for remote debug configuration and replugin configuration
To debug your application, create your run configuration as a remote application and configure the debugger using --java-opts. However, don’t forget to re-plug the debugger after every redeployment as a new process is created every time.
How to do the re-plug?
Second question, I think that my Eclipse actually be able to connect with the vertx app docker container. However, none of the breakpoints can be hit some how.
So here is the details:
1. I create a dockerfile which will install the gradle and copy in the source code, then in the end, gradle will use shadowJar to create the fat jar and I try to add the java-opts debug and hot redeploy when running the fatjar (I use the openjdk8 image instead of vertx3 image):
CMD (gradle shadowJar && java -agentlib:jdwp=transport=dt_socket,server=y,address=8000,suspend=n -jar build/libs/lrp-vertx-3.3.3-fat.jar --redeploy="src/**/*.java" --on-redeploy='gradle shadowJar')
Then I try to run the docker by exposing my app port and debug port at the same times
docker run --rm -it -v $(pwd):/somepath -p 8081:8081 -p 8000:8000 lrp-vertx-dev
The docker container runs properly which listening to the 8000 and redeploy mode
Starting a Gradle Daemon (subsequent builds will be faster)
:compileJava UP-TO-DATE
:processResources UP-TO-DATE
:classes UP-TO-DATE
:shadowJar UP-TO-DATE
BUILD SUCCESSFUL
Total time: 3.649 secs
Listening for transport dt_socket at address: 8000
Nov 08, 2016 8:12:26 PM io.vertx.core.impl.launcher.commands.Watcher
INFO: Watched paths: [/home/xpang/Documents/Projects/lrp-vertx-template/lrp-vertx/./src]
Nov 08, 2016 8:12:26 PM io.vertx.core.impl.launcher.commands.Watcher
INFO: Starting the vert.x application in redeploy mode
Starting vert.x application...
efb79038-9d71-4ca4-a0c6-897e91c99363-redeploy
The Verticle startsNov 08, 2016 8:12:27 PM io.vertx.core.impl.launcher.commands.VertxIsolatedDeployer
INFO: Succeeded in deploying verticle
I check the app in the browser, it can display the hello world message. As well, when I change the title, the hot redeploy works well.
In the Eclipse, I create Debug Configuration with Connection Properties Host:localhost, Port:8000
I run this debug mode, it will connect with the server, but not be able to hit any breakpoints I set

In the above image, I feel like the debug connection is established, but all the breakpoints I set inside the start method can not be hit when I load the page in browser.
I go through the Vert.x Github gradle/docker examples and understand that in most case gradle will trigger the whole build and even docker image generation. However, I want to isolate the vertx application build inside the container, so I didn't user gradle plugin to trigger the docker managements. As well, I didn't use the gradle wrapper because in the container, it still need to download the gradle which is similar to directly install.
Do anyone can help to point out where am I wrong? Really appreciate!