I would like to debug my Java application usually locally, but sometimes on a remote server. I was thinking about rsyncing the class files and the jar dependencies to the remote server (perharps in an ant script) that is run occasionally, and then running the application remotely by ssh and using an ssh tunnel for connecting to the remote JVM.
This is easily achieved by running the rsync part as a Builder and the ssh tunnel as an external tool which is ran before debugging sessions. However, I would like to simply launch the remote debug configuration and have it up & running. Ideally, I would like to execute some code snippet before Eclipse tries to connect to the remote JVM, and possibly have its output appear in a Console view.
Is there any way of achieving this with some plugins (it is not supported out of the box)? I suppose I could write a quick hack as an Eclipse plugin, but I would prefer not to reinvent the wheel.
If installing CDT is an option, then you could use its launch groups for running your external tool together with the normal launch configuration:

Alternatively you may want to have a look at the EclipseRunner plugin. While it can organize launch configurations in groups, I’m not exactly sure if the groups can be launched as such.