I really like the remote debugging facilities of the JVM. But I wonder how it works internally.
My assumption: It is done through a JVM feature where the running process is downloading/using the source-code from the attached remote-debugger (like IDE) It knows the line of the current stack-trace and then can jump to the respective IDE breakpoint. The communication of stack-trace and introspection of the application state is then done either through sockets or shared-memory (setting of remote debugger).
Has anybody interesting links/resources on that?
Функции отладки JVM предоставляются через архитектуру отладчика платформы Java (JPDA).
Сам JPDA состоит из следующих элементов:
Диаграмма, приведенная в структуре архитектуры JPDA, является хорошей отправной точкой. Дополнительными местами для поиска могут быть руководства, перечисленные на странице JPDA.
Архитектура отладки Java называется JPDA. Возможно, вы захотите прочитать документацию JPDA. В частности, в разделе Watch-through приводится пример взаимодействия IDE с JDI для получения значения в стеке.