[csw-maintainers] Proposed changes to the packages database

Philip Brown phil at bolthole.com
Thu Aug 20 17:52:31 CEST 2009


On Thu, Aug 20, 2009 at 3:46 AM, Maciej (Matchek) Blizinski <
maciej at opencsw.org> wrote:

> On Wed, Aug 19, 2009 at 10:13 PM, Philip Brown<phil at bolthole.com> wrote:
> > On
>
> > but sounds like the earlier answer of "yes, you can join between two
> > 'separate' databases" will get you everythig you need, I think.
>
> Data split into multiple databases will generally pose a problem for
> any non-custom system; '



What we're doing IS custom.



> if you look at any web framework (Rails,
> Django, CakePHP), it's usually expected that the complete information
> is contained within a single database.


But if it cant work by passing in DB.table references, instead of pure
[table] references, it's THAT system that is broken. Go fix THEIR code, or
find a better framework?



It's especially important in
> places where the database access layer is decoupled from the model; if
> at some level the application doesn't know the specifics of the
> database, it can't expect to know that there are two or more of them,
> and which class is stored in which database.


It doesnt have to "know" anything. It just has to transparently pass in
references.
And as I said, if it cant accept DB.table references in place of table
references, it's THEIR code that is broken.


Using multiple
> databases is database-engine-specific (you can't do cross-db joins in,
> say, Berkeley db, can you?),


berkeleydb isnt a "real" database, so that's a bad comparison.

you CAN do it in oracle, fyi.
So, we have
- ok in oracle
- ok in mysql


(Although what mysql calls a "database", oracle calls a "schema". but the
syntax is identical)

Any "database framework" that cannot support a fundamental, basic operation
supported by both mysql, and oracle, is broken.



> Is there a technical reason for a separate database for package
> information? It looks to me as if the tables from the CSW database
> could be moved to the MANTIS one.


Certainly. Proper data abstraction.
The mantis database is a "data object", if you will.
Violating object cohesion is bad programming.

PS: even "sqlite" supports "cross-database joins".  See their faq.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opencsw.org/pipermail/maintainers/attachments/20090820/f0a36b1d/attachment-0002.html>


More information about the maintainers mailing list