planet proxy/mirror ==> Re: [plt-dev] Fwd: [plt-scheme] Download links in PLaneT

From: Robby Findler (robby at eecs.northwestern.edu)
Date: Wed Jan 20 10:50:03 EST 2010

Meanwhile, I've set up

  http://planet.plt-scheme.org/archives/

which contains all of the .plt files, as well as their unpacked versions.

hth,
Robby

On Wed, Jan 20, 2010 at 9:45 AM, Robby Findler
<robby at eecs.northwestern.edu> wrote:
> Let me just double check something to be sure I'm on the same page.
> The planet mirror will completely avoid the current planet server,
> right? So, it has to be able to make the decision: given a planet
> package request (including the version number of the mzscheme loading
> the package) and the information on the mirror, which package to
> serve, right?
>
> I'm thinking you don't want to duplicate that code, right? Do you have
> a plan for that? One thing would be for you to actually run a planet
> server on the mirror, no?
>
> Robby
>
> On Tue, Jan 19, 2010 at 8:36 PM, YC <yinso.chen at gmail.com> wrote:
>>
>> On Tue, Jan 19, 2010 at 5:01 PM, Robby Findler <robby at eecs.northwestern.edu>
>> wrote:
>>>
>>> I'm not sure I'm quite getting what you want, but is using 'planet
>>> url' (via the planet commadline tool) sufficient?
>>
>>
>> Sorry for being unclear.  It's not about 'planet url'.
>>
>> Basically the planet servlet appears to expect a parameter called "lang",
>> which is set to the current version number.  And planet does not download a
>> package if the version number does not match the package's criteria.
>>
>> For example - with v4.2.3, if I run 'planet url bzlib base.plt 1 3' I get
>> the following url with a lang parameter
>>
>> http://planet.plt-scheme.org/servlets/planet-servlet.ss?lang=%224.2.3%22&name=%22base.plt%22&maj=1&min-lo=3&min-hi=%23f&path=%28%22bzlib%22%29
>>
>> And if I strip the lang param out, which gives us
>>
>> http://planet.plt-scheme.org/servlets/planet-servlet.ss?name=%22base.plt%22&maj=1&min-lo=3&min-hi=%23f&path=%28%22bzlib%22%29
>>
>> Passing the stripped url I get the following as a response instead of the
>> package itself
>>
>> "Binding for lang had improper format"
>>
>> Lang criteria is great for ensuring mzscheme downloading a package that
>> matches its version, but this does not work well for mirroring, which simply
>> tries to download all packages without caring about the versions.
>>
>> I can currently think of the following ways to solve this issue - there
>> probably are other ways I have not thought of, of course:
>>
>> Through planet server
>>
>> Enable "lang-less" download
>>
>> Either expose the directory structure where the plt files are held through
>> the web server, or
>> Modify the servlet so lang becomes optional
>>
>> Provide an API to query for minimum version necessary for each plt file
>> (this still requires one additional round trip)
>>
>> Through my mirroring client
>>
>> Try all mzscheme version number to see which one works (brute force)
>>>
>>> The .plt files are all there, but they aren't in a place that is
>>> served by the web server. I looked quickly into changing that; it
>>> isn't trivial, but it is certainly doable if 'planet url' isn't
>>> sufficient.
>>
>> I was hoping this can be a trivial change - wasn't trying to create work for
>> you ;)  If it's too much effort I can go with the brute force method until
>> you can look into it.
>>
>> Let me know if I need to provide additional clarifications.  Thanks,
>> yc
>>
>>
>


Posted on the dev mailing list.