Allow UseDelta option to specify a delta ratio
On Wed, Jan 11, 2012 at 6:52 PM, Allan McRae <email@example.com> wrote:
> On 12/01/12 07:42, Dan McGee wrote:
>> Rework the frontend and backend to allow passing a ratio value in for
>> UseDelta rather than having a hardcoded #define-d 0.7 value always used.
>> This is useful for those with fast connections, who would likely benefit
>> from tuning this ratio to lower values; it is also useful for general
>> testing purposes.
>> The libalpm API changes for this, but we do support the old config file
>> format with a no-value 'UseDelta' option; in this case we simply use the
>> old default of 0.7.
>> We clamp the ratio values to a sane range between 0.0 and 2.0, allowing
>> ratios above 1.0 for testing purposes.
>> Signed-off-by: Dan McGee <firstname.lastname@example.org>
> Ack-by: Allan
> Looks good from some basic testing here.
> My only thought (which is possibly full of bikeshed, so feel free to
> ignore...) was do we really want to stick with a ratio or move to an
> absolute size difference? *0.9 of a 100MB package is much more useful
> than 0.9 of a 1KB package.
$ pacman -Si | grep 'Download Size' | sort -k4 -n > /tmp/sizes.txt
4278 of 5490 packages available for me on x86_64 right now (77.9%) are
under 1MiB in the sync repos right now; 5342 are less than 20MiB
(97.3%). My guess is it isn't worth doing deltas at all for packages
in the <1MiB group as the time to reconstitute the package will take
longer than the download itself.
With that said, what would your bikeshed idea look like? I can imagine
something like `UseDelta = 5MiB` that would use deltas if the download
size saved for that particular package was > 5MiB or something; the
syntax seems a tad cryptic and not self-explanatory though.
|All times are GMT. The time now is 07:25 AM.|
VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.