Are you sure you are closing your JDBC connections?
Those can add up real quick if you are doing 3-5
database hits per page...
-August
--- "Lacerda, Wellington (AFIS)"
<[EMAIL PROTECTED]> wrote:
> Take a look on the list's history, because I saw
> something like you're
> describing related with (possible) memory leaks in
> JDBC-ODBC (not sure
> that's the problem), memory consumption and
> consequent performance
> degradation and even TOMCAT crashing.
>
> Take a look on that, it might be your case.
>
> Wellington Silva
> UN/FAO
>
> -----Original Message-----
> From: Federico Tello Gentile
> [mailto:[EMAIL PROTECTED]]
> Sent: Monday, October 23, 2000 5:44 PM
> To: [EMAIL PROTECTED]
> Subject: TOMAT slowing down a lot after a while
>
> I'm using Tamcat 3.1 to build a web application,
> but I find
> it extremely
> slow in my tests.
>
> I have 5 servlets that send between 2 and 5 SQL
> statements
> to an Access
> Database (using JDBC-ODBC) and forward at most 8
> beans to a
> JSP page each.
> The Beans are at worse a Vector with 16 small
> objects. I
> pass the beans in
> the request object.
>
> The first 7 to 10 page requests from the browser
> appear in
> less than a
> second, but after that it slows down a lot, taking
> about 10
> secs each page
> (the same pages that took a second before).
>
> I see that the swap file grows on every request
> about 2 MB,
> it's initial
> size is 64 MB and after 20 or so pages requested
> it's size
> is about 120 MB.
>
> The machine I'm using to test is a Pentium 133
> MHz, with 32
> MB RAM and
> Windows 98, J2SDK 1.3 with the standard
> configutarion.
>
> I've tried:
> Setting the initial heap size of the JVM to 8 MB
> and 32 MB
> with no change.
> Setting the maximun heap size to 32MB and 8 MB
> with no
> effect.
> Loading the Servlets at startup again with no
> change.
> Loading the JSP pages at startup with the same
> result.
> Using a thread pool (as shown in the Tomcat
> documentation),
> but nothing
> changed.
>
> Even if I call System.gc(); in one of the JSP
> pages the swap
> file continues
> to grow without limit.
> I print in the JSP page
> Runtine.getRuntime().totalMemory() -
> Runtine.getRuntime().freeMemory() and the value is
> allways
> below 2 MB
> (between 600KB and 1.600KB) on every JSP page
> call.
> I don't create big objects, in fact I don't have
> any big
> underlying model,
> just 5 Servelts that build the beans and pass then
> to the
> JSP pages.
>
> I'd expect the pages to load slower at first
> (complation,
> and so) but they
> load slower and slower due to the lack of memory.
> I imagine
> adding memory
> won't change anything since after 20 pages
> requested the
> sawp file reaches
> 120 MB, I can only imagine if I had several users
> at the
> same time.
>
> I hope you can give someadvice on the subject.
> Any idea is wellcome.
>
> Thank you.
>
>
__________________________________________________
Do You Yahoo!?
Yahoo! Messenger - Talk while you surf! It's FREE.
http://im.yahoo.com/