[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
|
[news.eclipse.tools.hyades] Re: Getting Started with Hyades in Eclipse 3.0 running a webapp on Tomcat.
|
- From: faizan@xxxxxxxxxxx (Faizan)
- Date: Wed, 15 Sep 2004 15:49:30 +0000 (UTC)
- Newsgroups: eclipse.tools.hyades
- Organization: http://news.eclipse.org
- User-agent: NewsPortal/0.25 (http://florian-amrhein.de/newsportal/)
Sebastien Mathy wrote:
> Faizan a écrit :
> > I have exact same situation and kind of stuck. I could not find any
> > documentation that actually help to run memory profiler for java web
> > application running under tomcat (or any webserver). It mentioned in the
> > help doc that this tool can be used to profile java web applications but
> > did not explain how.
> >
> You should start tomcat with this parameter :
> -XrunpiAgent:server=enabled (put it in the JAVA_OPTS var)
> You can after profile your webapp as an external java process
> Regards.
I still have problem. Here what I have done.
I am running tomcat on Win XP (local work station) and webapp that I want
to profile
First Scenario:
1- I added following in the catalina.bat file
JAVA_OPTS=-XrunpiAgent:server=enabled
org.apache.catalina.startup.Bootstrap
2- I started tomcat externally using the startup.bat
3- In eclipse when I try to attach the Java process (following docs
"Attaching to remote Java Process") I do not get any agent under the Agent
Tab. I have RASERVER running also. So I can not go any further.
Second Scenario:
1- 1- I added following in the catalina.bat file
JAVA_OPTS=-XrunpiAgent:server=enabled
org.apache.catalina.startup.Bootstrap
2- I follow the docs about "Launching a Java Application Remotely". I
click on "External Java Application"
3- On main tab
class -> org.apache.catalina.startup.Bootstrap
classpath -> I added all the jars in tomcat/bin and tomcat/server/lib
and tomcat/common/lib
I had to add these jars in the classpath so it can run and I also added
the tomcat/conf directory in the classpath. When I try to profile it gives
me following error in the console
Can't load server.xml
Can't load server.xml
Sep 15, 2004 11:52:54 AM org.apache.catalina.startup.Catalina start
INFO: Server startup in 0 ms
java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:284)
at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:422)
Caused by: java.lang.NullPointerException
at org.apache.catalina.startup.Catalina.await(Catalina.java:619)
at org.apache.catalina.startup.Catalina.start(Catalina.java:579)
... 6 more
I am kind of very confused and getting frustrated. I will greatly
appreciate if someone can give me steps to perform this task. Here what I
want to do
I want to profile a java J2EE web application running on tomcat 5.0.27.
Thanks a lot.
> > Any help will be greatly appreciated. Thanks a lot.
> >
> > Faizan
> >
> > Skip Hollowell wrote:
> >
> >
> >>Skip Hollowell wrote:
> >
> >
> >>>Does anyone have the basic steps I need to profile a J2EE webapp using
> >>>Hyades? I have installed the driver and the server, as per the 3.0
> >>>install instructions, but I can't quite get the next step? Is a WebApp
> >>>running in Tomcat considered an external Application?
> >>>
> >>>Currently I run Tomcat inside of Eclipse using the very fine MyEclipse.
> >>> Should I consider, for the profiling, just starting up Tomcat outside
> >>>of Eclipse and see what I can see?
> >>>
> >>>Pointers, hints, and tips are all greatly appreciated. Hell even
> >>>telling me to RTFM (and where that manual is located) would probably be
> >>>a step above where I am now.
> >
> >
> >>According to the post on 8/30, I need to run the tomcat on it's own and
> >>then run Hyades against that... I am really trying to read before I
> >>write. Honestly.
> >
> >
> >