[Webtest] [dev] Memory Leak?
Dierk Koenig
webtest@lists.canoo.com
Sat, 16 Jul 2005 10:00:30 +0200
Hi Ritesh,
all references are hold within the context of a testSpec at most.
Did you try to use a memory profiler?
I did some some memory profiling lately and took snapshots between
testSpec. It couldn't find a single single leaking byte.
As Lisa said, too large result files can be a problem because they
are parsed before adding to it. In any case it is good practice for
large testsuites to devide then into subsuites and let them
report in to different files. This way, you can also profit from
running them in parallel.
I'm always open to improve the codebase. Feel free to open a JIRA
issue and attach a patch. Sometimes our goal of avoiding
duplication leads to constructions that may appear convoluted.
That's the DRY vs KISS trade-off.
cheers
Mittie
> -----Original Message-----
> From: webtest-admin@lists.canoo.com
> [mailto:webtest-admin@lists.canoo.com]On Behalf Of Ritesh Trivedi
> Sent: Freitag, 15. Juli 2005 21:12
> To: WebTest@lists.canoo.com
> Subject: [Webtest] Memory Leak?
>
>
> Hi,
>
> I am experiencing a memory leak in canoo, when calling canno based ant
> targets multiple times in loop. My JVM runs out of memory.
>
> It took me a lot of time to find the issue(s). Potential candidates
> for the memory leak are
>
> 1. why is Step keeping reference to ant Project? Step is extending
> Task and each Task is configured to have reference to Project by Ant
> framework.
>
> 2. Also looks like there is a lot of places where steps are stored in
> arraylist. I do not see all the references are getting cleaned up.
> This may leave all the references to steps and objects in the steps in
> heap
>
> 3. Lots of convoluted references to objects - pointing to each other -
> its very difficult to profile and code and find out where the memory
> leak is.
>
> I havent made a lot of progress due to memory leaks, Can someone who
> is better versed with the code and leak issues throw some light?
>
> I will really appreciate faster response.
>
> Thanks
> Ritesh
> _______________________________________________
> WebTest mailing list
> WebTest@lists.canoo.com
> http://lists.canoo.com/mailman/listinfo/webtest
>