[Rubygems-developers] Updating source index is slow

Jim Weirich jim at weirichhouse.org
Wed Nov 10 12:54:33 EST 2004


Hugh Sasse Staff Elec Eng said:
> On Wed, 10 Nov 2004, Eivind Eklund wrote:
>> You already do something quite a bit like this; a GET is started, and
>> from this GET you retrieve the Content-Length.  If this match the cached
>> data, you use that; if not, you start a new GET and retrieve the file.
>
> I really don't like this algorithm.  The program uses open-uri for
> most of its work, which is great for getting things going,
> proof-of-concept and so on, but for a scalable application I think
> we should aim to move to Net::HTTP and follow the protocol more
> closely. [...]

I concur.

-- 
-- Jim Weirich     jim at weirichhouse.org    http://onestepback.org
-----------------------------------------------------------------
"Beware of bugs in the above code; I have only proved it correct,
not tried it." -- Donald Knuth (in a memo to Peter van Emde Boas)



More information about the Rubygems-developers mailing list