I have been playing with the Eclipse Profiler open source plugin to profile a J2EE app.
The profiler lives at
http://eclipsecolorer.sourceforge.net/index_profiler.html
As you can see it is very feature rich for an open source plugin.
I got it working to profile OC4J 9.0.3 using the following extra command line options to start the server:
-XrunProfilerDLL:1 -Xbootclasspath/a:jakarta-regexp.jar;profiler_trace.jar;commons-lang.jar -D__PROFILER_PACKAGE_FILTER=__A__com.evermind.server.OC4JServer;__M__sun.;__M__com.sun.;__M__java.;__M__javax.;__M__org.apache.;__M__com.evermind.;__M__oracle.;__M__com.oracle. -D__PROFILER_AUTO_START=0 -D__PROFILER_TIMING_METHOD=0
So basically all it needs is a few more command line options than what MyEclipse is using, but it is really fiddly to set up.
What would be cool would be:
1. Integrate the Eclipse Profiler plugin with MyEclipse
2. Provide an option on the application server Launch preference page to launch in Profiled mode (as well as the current Debug and Run). This would automatically add the correct command line parameters when starting up the server inside eclipse, and switch to the Eclipse Profiler perspective.
This would add a serious enterprise level feature set to MyEclipse for a reasonably small amount of work.
Cheers,
Jon Nermut