How can I debug code that is called using java reflection?

I am using an application that is deployed on a J2EE application server, the application implements jar class loader files in the JVM inside the application, there are test cases inside these jar files that implement the common interface, through java reflection I dynamically call (by name) these test cases, the problem is that it looks like a black box, and if the test script does not work, I need to work hard to find what happened to start the application registration server, is there any way to debug the code of the test cases? or any suggestion at all? thanks, sorry for the long story ..

+3
source share
2 answers

You can use the Java remote debugging tool. I did something like this before, and I would just set a breakpoint in the test that failed. This page describes how to configure remote debug termination in eclipse. How to enable debugging depends on the application server you are using.

+1
source

You can connect to a remote Java EE application server using IntelliJ and execute code line by line.

-1
source

Source: https://habr.com/ru/post/1727030/


All Articles