Registry schema cleanup
Clemens Lang
cal at macports.org
Tue Nov 18 11:48:56 PST 2014
Hi all,
I'd like to clean up the database schema of the registry. We have a couple
of fields in there that are currently unused, as well as a few possible
indices that could improve performance and at least one index that is
actively harmful.
In detail:
I'd like to drop the `url' column from the ports table. All ports I have
installed have this set to NULL and I couldn't find a use-case where it
was being used. I tried installing a port from a URL, but that doesn't
set the field either.
Even worse, the `url' column is part of a unique index `UNIQUE(url,
epoch, version, revision, variants)', which is bad, because if `url' is
always NULL, that means you can never install two ports with the same
tuple of (epoch, version, revision, variants). I'm surprised we haven't
hit this yet.
Consequently, this implies removal of the port_url index.
More information about the macports-dev
mailing list