Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 14 May 2007 12:33:24 +0100
From:      Thomas Sparrevohn <Thomas.Sparrevohn@btinternet.com>
To:        "'Michel Talon'" <talon@lpthe.jussieu.fr>
Cc:        freebsd-hackers@freebsd.org
Subject:   Re: DPS Initial Ideas
Message-ID:  <200705141233.24767.Thomas.Sparrevohn@btinternet.com>
In-Reply-To: <20070514082512.GA25544@lpthe.jussieu.fr>
References:  <20070514082512.GA25544@lpthe.jussieu.fr>

next in thread | previous in thread | raw e-mail | index | archive | help

On Monday 14 May 2007 09:25:12 'Michel Talon' wrote:
> On Mon, May 14, 2007 at 12:33:23AM +0100, Thomas Sparrevohn wrote:
> > 
> > converted INDEX
> > into postgresSQL because I was playing around with making a message queue
> > based approach -
> > and it becomes BIG - The only table structure difference from the current
> > format was that I 
> > was able to track "who is depending on" a port - which I am pretty sure
> > could be handled in the
> > current framework - e.g. we could add a file having the depending port names
> > or so
> 
> 
> niobe% cp /usr/ports/INDEX-6 .
> niobe% sqlite3 index.db
> sqlite> CREATE TABLE index6 (
> pkgname varchar(1),
> path varchar(1),
> prefix varchar(1),
> comment varchar(1),
> descr varchar(1),
> maintainer varchar(1),
> categories varchar(1),
> build_deps varchar(1),
> run_deps varchar(1),
> website varchar(1),
> extract_deps varchar(1),
> patch_deps varchar(1),
> fetch_deps varchar(1));
> sqlite> .import INDEX-6 index6
> ... completes in less than 2 seconds
> sqlite> select * from index6 where path = "/usr/ports/accessibility/atk";
> atk-1.12.4|/usr/ports/accessibility/atk|/usr/local|A GNOME accessibility
> toolkit
> (ATK)|/usr/ports/accessibility/atk/pkg-descr|gnome@FreeBSD.org|accessibility
> devel|gettext-0.14.5_2 glib-2.12.9 libiconv-1.9.2_2 libtool-1.5.22_3
> perl-5.8.8 pkg-config-0.21|gettext-0.14.5_2 glib-2.12.9 libiconv-1.9.2_2
> perl-5.8.8
> pkg-config-0.21|http://developer.gnome.org/projects/gap/||libtool-1.5.22_3|
> 
> niobe% ls -lh INDEX-6 index.db 
> -rw-r--r--  1 michel  lpthe   9,5M 14 mai 10:00 INDEX-6
> -rw-r--r--  1 michel  lpthe    12M 14 mai 10:12 index.db
> 
> Where is this huge increase in size?
> Admittedly, i have not created indexes, etc.
> Compare this to the portsdb created by portupgrade from the same INDEX-6
> 
> niobe% ls -lh /usr/ports/INDEX-6.db
> -rw-r--r--  1 root  wheel    21M 16 fév 13:36 /usr/ports/INDEX-6.db
> 
> Surprise, surprise, the BerkeleyDB suddenly appears less glorious.
> 
> 

That you table structure does not even full fill 1st normal form ;-) - You need to convert that
into independent tables in order to get it on a reasonable normal form format 




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200705141233.24767.Thomas.Sparrevohn>