Memory leak in java program using OTA API
We have developed a java application to retrive data in HP Quality Center using OTA layer. We have additional layer
of java-com bridge which is used by the java application. (The bridge is generated over OTAClient.dll, and provides
wrapper for its classes) We are seeing issue of memory leak with this application. (the memory keeps on increasing).
To narrow down the issue we have written sample application in java (access data using bridge) and vbscript. Both
does same thing (iterate and print defect fields for a project)
Here is snippet from vbscript
Dim BugFactory, BugList
Set BugFactory = QCConnection.BugFactory
' Get a list of all the defects.
Set BugList = BugFactory.NewList("")
wscript.echo "Total Bugs: "&BugList.count
For Each Bug In BugList
wscript.echo Bug.Priority&" "&Bug.Summary&" "&Bug.DetectedBy&" "&Bug.Status&" "&Bug.AssignedTo
the sample java does same thing. but here is the difference in their behaviour;
when I repeatedly query bug data (in same program using same connection) there is continuous increase in memory for
both, but for VBscript the memory consumption drops suddenly and then start increasing. This never happens for java
program and the working set size keeps on increasing.
I am using perfmon to monitor the memory usage.
Has anybody done similar things before and faced similar issues. Any help would be much appreciated.
Re: Memory leak in java program using OTA API
That issue has already been validated as QC memory leaks by the HP support (see http://tdforums.tdadmins.com/index.p...6059&hl=).
I don't know if they corrected it in more recent patches (there is no word about that in the release notes, as far as I remember).