[Soc-coordination] GSoC - Apt Ordering - Report 3

Christopher Baines cbaines8 at gmail.com
Sun Jul 3 20:20:48 UTC 2011


Hello,

Now if you read my last report[1], you will know that I was looking at
implementing batch processing of packages. As I am now working full
time, soon after submitting that report I began looking at how to do
exactly that. However I quickly realised that things are not quite as
simple as I appeared to present them in my last report.

Implementing batches would have required a lot of work, because of the
modification of the existing code (managing package processing, the
cache...) and the new code needed (managing batching of packages), could
this be achieved quicker and easier, was I trying to over engineer this
solution? So I began thinking in terms of, how do I change/tweak the
existing system to get the desired results? So talking to David
(DonKult) and Michael on IRC, David mentioned “what about working on
immediate configuration instead. If the issues we have with it are fixed
we could in theory enable it for all packages: aka we have minimal
batches… “. 

So, what is immediate configuration you might ask? Well the clue is in
the name, if you watch apt install/upgrade packages, it will unpack
packages, then set them up (configure them). But these two operations
for most packages happen is two distinct stages, for some packages
(essential and important packages) APT configures  them immediately
after unpacking. As David explained if this is extended to all packages
you could would effectively get very small batches. Problem is immediate
configuration does not work for all packages.

David very kindly set me off with a patch containing a APT test file
(micro environment to test a specific feature), that indicated one such
problem. I have pushed the fix to my new apt branch on launchpad, along
with the configuration verification code[2].

I then asked David for another example of a issue to solve, he gave me a
command to run, and turned this in to a test
(test-package-reinstallation), like the previous test. This test is in
my branch, but I have not committed a fix yet, I have been having a lot
of very confusing  problems with the DepAdd method in the package
manager class. For some reason when run in the above test, the DepAdd
method according to my tests picks up incorrect flags and states for one
of the packages. I hope to talk to either David or Michael for help with
this in the coming week.

A few more modifications are needed though, one of the more important is
the ordering. At the moment configuration ordering (ordering of a group
of packages before configuration) only takes in to account dependencies.
What would be good is to also order by fetch time (normally download
size), otherwise you could be stuck downloading a large package when you
could have downloaded and installed several smaller packages, much
better utilising the systems resources. 

Chris

1.
http://lists.alioth.debian.org/pipermail/soc-coordination/2011-June/001015.html | http://lists.debian.org/deity/2011/06/msg00064.html
2. https://code.launchpad.net/~cbaines/apt/apt-chris
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part
URL: <http://lists.alioth.debian.org/pipermail/soc-coordination/attachments/20110703/c9d712a5/attachment.pgp>


More information about the Soc-coordination mailing list