David
David

Reputation: 1237

How do I step into JDK source code when debugging remotely in Eclipse

I can't figure out how to step into "JDK" classes when I'm debugging remotely with Eclipse Kepler.

I have no problems stepping into "JDK" classes (like java.lang.Runtime) provided that I'm debugging a Java application launched by Eclipse (I'll call this "local"). However, when I attempt to debug the same application (launched with an InstallAnywhere LaunchAnywhere launcher) as a Remote Java Application on localhost, I can't step into JDK classes (I'll call this "remote").

In both cases (local and remote), I can step into my classes. But when I get to a method call in a JDK class while debugging remotely, Eclipse treats Step Into as Step Over. I'm using the same JDK for the local and remote debug session.

Is this an inherent limitation of remote debugging, or am I missing a configuration setting?

Upvotes: 2

Views: 4404

Answers (3)

王奕然
王奕然

Reputation: 4059

window->preference->java->install->click add->standard VM->next: JRE HOWM :JDK PATH(NOT JRE PATH!)

if no source in rt.jar you should on rt.jar source Attachment to configure the source path. that's all

Upvotes: -1

Malik Firose
Malik Firose

Reputation: 389

You will find the src.zip inside the JDK folder please add it to the debug configuration as an external archive in the source tab

Upvotes: 0

Katona
Katona

Reputation: 4901

Check the following:

  • ensure that the Source Lookup Path contains the rt.jar using Edit Source Lookup dialog during the debug session.
  • the line number attributes are included the compiled classes which you are remote debugging, check this if you compiled them with eclipse.
  • ensure that the remote application which you are debugging uses a JDK instead of a JRE, since JREs doesn't include debugging information

Upvotes: 4

Related Questions