[pacman-dev] Binary Database
Hi everyone, I am writing this mail for a variety of reasons. First of all, some discussion in the forums, and then, because it's something that I've been thinking about for a long time. There have been many requests, AFAIK, for bringing pacman a binary database. Currently I'm writing a libalpm frontend, with some other guys (works in progress are @ KDEMod Forums), and we would really like to bring some improvements to Alpm, starting from its database. Every time this question arises (by doing a search through the forums), the answer is always "show us some code first". Well, nothing wrong with that, and unfortunately I have nothing to show now, but for a simple reason. Maybe I did not search well, but I still haven't found an answer to the following question: "Are pacman/alpm devs interested in having a binary database instead of the text based one?". If there is no interest, it would be useless to start coding. So I'd like to hear some voices/opinions. Then I will be more than happy to show some code. Cheers, Dario
On Sun, Mar 09, 2008 at 09:50:42PM +0100, Dario Freddi wrote:
Hi everyone,
I am writing this mail for a variety of reasons. First of all, some discussion in the forums, and then, because it's something that I've been thinking about for a long time. There have been many requests, AFAIK, for bringing pacman a binary database. Currently I'm writing a libalpm frontend, with some other guys (works in progress are @ KDEMod Forums), and we would really like to bring some improvements to Alpm, starting from its database.
Every time this question arises (by doing a search through the forums), the answer is always "show us some code first". Well, nothing wrong with that, and unfortunately I have nothing to show now, but for a simple reason. Maybe I did not search well, but I still haven't found an answer to the following question: "Are pacman/alpm devs interested in having a binary database instead of the text based one?".
If there is no interest, it would be useless to start coding. So I'd like to hear some voices/opinions. Then I will be more than happy to show some code.
I was going to reply on bbs, but I will reply here now :) I think we are more interested in trying to improve the current text based one rather than switching to a binary database, at least as a first step. For example, for the sync db, we could directly read from the archive : http://bugs.archlinux.org/task/8586 A second point of interest is unifying the format of the meta-info files inside the package (.PKGINFO) and the ones inside the database (depends / desc). Having just one format would simplify the code. We could also reduce the number of files in the sync and local database by merging them, which would reduce the impact of fragmentation and slow filesystems. http://www.archlinux.org/pipermail/pacman-dev/2007-June/008601.html Otherwise, if we want to experiment with different backends, it would probably be a good idea to try abstracting the backend code, so that we would have all specific backend code in the same place, and have the possibility to easily switch between several ones. That was also discussed ages ago, in the same link as above : http://www.archlinux.org/pipermail/pacman-dev/2006-March/005702.html More recently, there was an attempt of a sqlite backend : http://www.archlinux.org/pipermail/pacman-dev/2008-January/011011.html As you can see, this raises several problems of migrating the current code base. And then there is also the problem of migrating the databases. Well, I hope that throwing out some random ideas about the backend that were discussed here wasn't too confusing. But I think there is definitively an interest for improving the backend in one way or another.
participants (2)
-
Dario Freddi
-
Xavier