I have a procedure that produces a .CSV file of data requested by the user. There is no limitation on the amount of data that may be obtained, so I decided to dump the entire database (approximately 900,000 entries). First these entries are read into a queue and sorted, then presented to the user. So far so good.
I expected the queue to grow rather large, so I fired up Task Manager to see how much RAM was used. The number climbed to 150M before the data was written to the disk (which I find to be a high, but acceptable number). However, after the data is written and the procedure is executed, the RAM does not appear to be released.
I had assumed that the RAM would automatically be freed after the local source procedure ended (it IS a local queue), but apparently not.
I typed the queue, set a reference variable, and tried using NEW and DISPOSE. No difference.
I logged out, thinking that maybe garbage collection would take care of that. No good, either.
On a positive note, I ran the same report a second time and the memory usage only increasd by about 4M, not another 140M as I had expected.
I do have a five hour timeout on the session, so I will test it with a 20 minute session timeout so it will have a chance to clear, but that should only apply to session variables, not queue memory usage.
I have had this problem since day one where it appears that my NetTalk program is using but not releasing RAM. Even when sitting idle, the RAM usage (according to Task Manager) continues to increase. After several days or weeks of this, the RAM usage becomes astronomical. There are no strange data types in the queue that need to be handled individually, just SHORT, LONG, DECIMAL and STRING variables.
What am I doing wrong? Is there an ABC-specific method to free up the RAM? I am, after all, fairly new to ABC and may miss some of its idosyncracies.
Or is this simply that Task Manager is confused? Is there some other software that I can use that will accurately display how much RAM is being consumed by my NetTalk app?
Thanks!
Rob Mikkelsen