I just found a blogpost about the
EAV-Pattern, which in turn refers to a recent issue of
PHP Architect about the same topic. So I thought I'll sum up the progress with my idea on an improved content storage method for the next generation of
eZ Publish.
Some weeks ago I
posted about an idea of mine for an alternative content storage method for Content Management Systems. Since this is a pet project of mine, I have only limited time to work on it between my regular projects. But I'll be holding a presentation about it in two weeks, on our weekly
web meeting. So I hope that I can convince my bosses to accord me a little bit more time after that.
So far I tried to hack a first proof-of-concept implementation. The first thing I discovered was, that I need a very easy to use API for
DDL statements. Therefor I forked out a small project to build an API on top of the
DatabaseSchema component of eZComponents. This will allow me to build DDLs similiar to the following snippet (This is an older example, the current syntax has changed a little bit):
CODE:
$schema->addTable()
->addColumn( 'content_object_id', ezcDbSchema::INTEGER )
->addColumn( 'version', ezcDbSchema::INTEGER )
->addColumn( 'locale', ezcDbSchema::TEXT )
->addColumn( 'name', ezcDbSchema::TEXT )
->addColumn( 'creator_id', ezcDbSchema::TEXT )
->addColumn( 'created', ezcDbSchema::TIMESTAMP )
->addColumn( 'published', ezcDbSchema::TIMESTAMP )
->addIndex( 'primary', 'content_object_id',ezcDbSchema::ASC,
'version', // Defaults to ASC
'locale', ezcDbSchema::DESC )
->isPrimary( TRUE )
->isUnique( TRUE )
->addIndex( 'name' ) // Default Index name = Column name
;
I'll post the PDF of my presentation as soon as it'll be ready. If you're interested in this topic I'd be glad to discuss it with you or even collaborate.
As written in my blogpost about my Content Storage Component Project, I needed an easy way to dynamically manipulate database schemas from inside a PHP application. Therefor I started and finished now an add-on to the Database Schema eZComponent. I dis
Tracked: Aug 07, 09:08