Re: Adding .db support to pkg_tools

I think this is a really bad idea. The problem with the tools is not
with the files. It is that the files need to be parsed on each run,
often recursively, and your solution would not help at all.

Parsing one file isn't expensive; parsing several hundred files
to find one bit of information is expensive.

The database(s) should just be a cache of the information stored in the

Bingo! As long as the .db version can be easily recreated
from scratch from the master data stored in the same files
as always, it doesn't really matter if the BDB is occasionally
corrupted, as long as it can be rebuilt fairly quickly.

So, the key points are:
* Use the .db file for lookups that can't be done quickly
against the existing data. In particular, look for operations
where the pkg tools have to scan a lot of files to verify a single
* Ensure the .db file can be deleted and rebuilt from scratch
from the data in the regular files.

Tim Kientzle
freebsd-hackers@xxxxxxxxxxx mailing list
To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@xxxxxxxxxxx"

Relevant Pages

  • RE: Network Connections/Mappings dropped
    ... The new DC was rebuilt from scratch on a new PC; ... when you loose your mapped drives do you loose ... >Aree there any messages in the event logs that would ...
  • openssl/ssh upgrade
    ... and now I cant su to root. ... I have rebuilt the box from scratch with the new version but still no luck. ...
  • Re: [PATCH] sh: maple: add support for the Maple mouse on the SEGA Dreamcast
    ... On Monday 29 December 2008 14:19:42 Mike Frysinger wrote: ... Just rebuilt the whole thing from scratch with that turned on and no ... extra warnings at all. ...
  • Re: CListCtrl::HitTest error arg invalid
    ... > LVHITTESTINFO hti; ... > AliR. ... I completely rebuilt the project from scratch, ...
  • Re: Generators vs. Functions?
    ... from scratch in the first place. ... Resuming a generator is faster than calling a function. ... with the same number of name lookups in both pieces of test code. ... insignificant fraction of the total execution time. ...