This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 60322 - OutOfMemoryEcxeption, respond slowly
Summary: OutOfMemoryEcxeption, respond slowly
Status: RESOLVED INVALID
Alias: None
Product: serverplugins
Classification: Unclassified
Component: Tomcat (show other bugs)
Version: 4.x
Hardware: PC Windows XP
: P1 blocker (vote)
Assignee: Sherold Dev
URL:
Keywords: PERFORMANCE
Depends on:
Blocks:
 
Reported: 2005-06-21 11:43 UTC by mgsimon
Modified: 2005-09-05 10:13 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description mgsimon 2005-06-21 11:43:10 UTC
If i deploy my webapp in the internal or external tomcat the requiered memory is
very high.
I have to increase the use of memory to resolve the OutOfMemoryException.
catalina.bat
set JAVA_OPTS=-Xms256m -Xmx512m
netbeans.conf
netbeans_default_options="-J-Xms256m -J-Xmx512m -J-XX:PermSize=128m
-J-XX:MaxPermSize=512m -J-Xverify:none"
Now the respond time is very slowly, my cpu will be used up to 100% for some
minutes to deliver the respond.
If I deploy my webapp in a standalone servletengine (tomcat any version) the use
of memory will be less than 60 MB and the respond time is in a normal perfomance
(some seconds).
How do I can resolve or determine the memory leak?
Thank for any helpful resond,
mgsimon
Comment 1 mgsimon 2005-06-21 12:00:14 UTC
the ussage of memory

first  java.exe 288.388 K
second java.exe 326.120 K

after the first respond.
Comment 2 zikmund 2005-06-21 12:35:49 UTC
Do you mean that you can see the difference even when using (deploying and
running) one project on the same Tomcat started from IDE and started without IDE?
Comment 3 mgsimon 2005-06-21 12:46:05 UTC
No, the ide starts two virtual machines.
One for the ide, the other for tomcat.
I need help to determine the memory leak,
to resolve the very long respond time 
or exits any possibility to tune the tomcat integration?
Now it is not possible to work in this environment.
Comment 4 zikmund 2005-06-21 12:53:25 UTC
Well I understand, but I have no idea what can be the reason. Could you please
try to deploy and run your application:
  A) on Tomcat started outside of the IDE
  B) on the same Tomcat added as external Tomcat into IDE and started from IDE?

Thanks.
Comment 5 mgsimon 2005-06-21 12:55:09 UTC
The difference (usage of memory after the first request) with and without ide:
IDE Netbeans 4.1 (or 3.6):
respond time: some minutes
java.exe 325.392 K
java.exe 288.380 K
Tomcat 5 (standalone without IDE):
tomcat5.exe 96.168 K (with some more webapps as the ide!)
respond time: some seconds
Comment 6 Sherold Dev 2005-06-21 12:55:20 UTC
This doesn't seem to me like a NB bug very much. Can you please response these
questions

1. What throws the OutOfMemoryError, NetBeans or Tomcat? Can you provide the
stack trace and Tomcat output?
2. How much memory does your system have?
3. Didn't you modify Tomcat servlet.xml configuration file somehow?
4. Couldn't be to problem caused by some other already deployed application?


Comment 7 mgsimon 2005-06-21 13:14:57 UTC
1. What throws the OutOfMemoryError, NetBeans or Tomcat? Can you provide the
stack trace and Tomcat output?
I think Tomcat, how do I can provide the stack trace?
2. How much memory does your system have?
I have 2 GB RAM (with swap 4 GB).
3. Didn't you modify Tomcat servlet.xml configuration file somehow?
I didn't modify the servlet.xml.
4. Couldn't be to problem caused by some other already deployed application?
No other nonstandard-application will be deployed.

I have a idea. It is possible that the problem may concerns the http-monitor?
Many objects will be saved in the session, it is possible to deactivate the
http-monitor for a test?
Comment 8 Sherold Dev 2005-06-21 13:46:00 UTC
Yes, I wanted to suggest you the very same thing.

To deactive the HTTP Monitor go to the Window | Runtime | Servers | your Tomcat
instance - > Properties and uncheck the "Enable HTTP Monitor" context menu.

Now, restart the Tomcat server for the changes to take effect.



Comment 9 mgsimon 2005-06-21 13:58:00 UTC
Yes, in my context is the problem the http-monitor.
I have to talk with the developer to use the sessioncontext carefully. :-)
Thank for the help to resolve my problem.
Comment 10 Sherold Dev 2005-06-21 14:10:35 UTC
Setting the proper resolution.
Comment 11 Sherold Dev 2005-06-21 14:12:35 UTC
Marking as INVALID.
Comment 12 mgsimon 2005-06-21 14:17:34 UTC
Maybe this performance problem should be explained in the faq?
Comment 13 zikmund 2005-06-21 14:22:26 UTC
We don't have any example of a real-world WebApp which would cause this problem.
I think it can happen only in really extreme WebApps (mostly caused by bugs or
misusage of session context etc.)
Anyway if you have a real-world example, please let us know.
Comment 14 mgsimon 2005-06-22 10:07:21 UTC
I want to analyze this problem in detail.
First how do I can determine the http-monitor protocol?