Debugging through IDEA

Hi,

I am a new starter to IDEA, there are a lot of things to discover and learn, lots of details.

What I am trying to find out is about debugging my code. I managed to run the debug, but my problem is as long as you do not place the break point the debug process will not be triggered.
In Eclipse-php(and XDebug), once I run my application in the browser, the debug process was starting automatically, without putting any break-points.

The thing is, when you have hundreds of classes, and you run your application you have to know which class(es) will be called by the application you are running in the browser. Is there a way in IDEA to trigger the debug process automatically?Do I need to configure any external tool for that, such as XDerbug or Zend Debug..?

If you could advise on that, I will be very happy.

Thanks for your time.

6 comments
Comment actions Permalink

You can integrate XDebug with IntelliJ so you can have the same functionality. This is relatively simple just follow these steps: http://www.jetbrains.com/idea/webhelp/configuring-xdebug.html
.

0
Comment actions Permalink

Hi,

Thanks a lot for the reply. I have checked the link you have sent to me. It is talking about PHP, but  am using Java. Not sure If I can still use the XDebug for java applications.

thanks again.

0
Comment actions Permalink

Oh.

You can put breakpoints on enter/exit of specific methods, on access of particular fields, or when any exception is thrown. But you cannot break on EVERY method.

If you need to trace execution to see what classes are being used then use a profiler?

0
Comment actions Permalink

Profiler, this sounds what I am looking for. What is it and how can I use it, could you please give some more details?

Many Thanks

0
Comment actions Permalink

YourKit and JProfiler are two very polished, popular commercial profilers that have free trial versions available. They both easily integrate into IDEA through built in configuration menus:


Or VisualVM is free and still quite good, to integrate it you can add a plugin to IDEA that will launch it:

0

Please sign in to leave a comment.