TOracleQueue memory leak?

arunb

Member
When i use the TOracleQueue component to dequeue, the memory foot print of the application on an average grows by around 50 bytes per dequeue. My application has a lot of transactions and it eats up the entire memory very soon. I have a sample code which demonstrates the problem. The first time the dequeue happens the memory jumps by around 400 bytes and at the end of the loop, the memory grew by more than 500 bytes. The memory stays there even after the session logoff. when the application starts the memory is around 5500k and when i click the button and the db login happens the memory jumps to around 12500K. On the first dequeue the memory increases to 12900 and progressively increases in small quantites after that.Is there anything i need to do clear the memory?

procedure TForm1.Button2Click(Sender: TObject);
var i : Integer;
begin
oraQueue.QueueName := 'trade_queue';
oraQueue.DequeueOptions.Wait := 10;

with OraSession do
begin
LogonUsername := 'x';
LogonPassword := 'x';
LogonDatabase := 'testdb';
Logon;
end;
for i:=0 to 9 do
begin
with oraQueue do
begin
Dequeue;
if not MessageProperties.TimeOut then
begin
ListBox2.Items.Add(Payload.GetAttr('TRANS_ID'));
OraSession.Commit;
end;
end;
end;
OraSession.LogOff;
end;
 
Back
Top