[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

nethttp memory leak on long-running daemon

sjoonk

2/10/2007 4:03:00 AM

I used nethttp library to my small program. My program is simple.
It loops and call nethttp get method at every loop.
But when this program run for a long time, memory was up and up
eventually.
Here's my program. What's the matter??

require 'net/http'
loop do
begin
url = "http://localhost/test.html"
resp = Net::HTTP.get(URI.parse(url))
rescue
# do nothing
end
sleep rand(0.1) # just a wait
end

--
Posted via http://www.ruby-....