<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Word 14 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:#0563C1;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:#954F72;
        text-decoration:underline;}
p.MsoPlainText, li.MsoPlainText, div.MsoPlainText
        {mso-style-priority:99;
        mso-style-link:"Plain Text Char";
        margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
span.PlainTextChar
        {mso-style-name:"Plain Text Char";
        mso-style-priority:99;
        mso-style-link:"Plain Text";
        font-family:"Calibri","sans-serif";}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri","sans-serif";}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-US" link="#0563C1" vlink="#954F72">
<div class="WordSection1">
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span style="color:black">Hi All,</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span style="color:black">We are facing a problem where the memory consumed by application is growing very high and the consumed memory not getting released even if required work
 is complete. The memory management of this application is mainly driven by Omni ORB [OMNI ORB version 4.1.4]</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span style="color:black">Our server side application (in C&#43;&#43;) acts as servant application which queries DB and fetches records and then fills a CORBA sequence. Then the requester
 application (here Omni ORB) takes care of delivering that data to User interface layer (written in VC&#43;&#43;).
</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span style="color:black">Now omni is the intermediate layer working between our core server application (say querying from DB) and our UI. So we are depending on omni CORBA sequence
 completely for the memory allocation and de-allocation</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span style="color:black">We are seeing from the glance command that: during this process the heap memory (acquired for CORBA sequences in consideration) is growing to an extent
 proportionately with the number of records we are operating or fetching from DB. But then it never goes down even if the data is surrendered to UI by omni. Initially we thought this as a leak but then realized that the memory growth is not consistently happening.
 Assume that we have fetched say 10000 records from DB and returned back to UI through omni. Then subsequently if we are querying a small section of data, then memory does not grow further. It appears that omni uses a different kind of memory management as
 opposed to traditional new/delete. Because the memory address used in the first iteration is getting re-used in the second iteration. However that consumed memory does not come down at all.</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span style="color:black">Also we are even seeing at times that: if the UI logged in user is different and the request to query DB goes to a different application thread, then again
 for that thread, memory is allocated from heap. Overall we are seeing that a huge amount of memory is being allocated and reserved for its operation instead of releasing it after the request has been served. The issue here is the memory usage grows up very
 high. </span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span style="color:black">The leak detector tools are clearly telling that, there are no leaks in our application or in omni. With this we are getting an impression that it&#8217;s a
 different kind of memory management technique. But then the concern is, for each serving thread if it allocates good amount of heap memory and keep with it as working area/memory then we are running out of resources.</span><o:p></o:p></p>
<p class="MsoNormal" style="mso-margin-top-alt:auto;mso-margin-bottom-alt:auto"><span style="color:black">Please highlight if there is any design glitches (or any recommendations)</span><o:p></o:p></p>
<p class="MsoPlainText">Thanks &amp; Regards,<o:p></o:p></p>
<p class="MsoPlainText"><o:p>&nbsp;</o:p></p>
<p class="MsoPlainText">Shelendra Agarwal<o:p></o:p></p>
</div>
</body>
</html>