[Product-Developers] Design advice for collective.alchemyindex

Roché Compaan roche at upfrontsystems.co.za
Sat Oct 4 11:20:08 UTC 2008


On Fri, 2008-10-03 at 18:51 +0200, Roché Compaan wrote:
> I'm wrapping up collective.alchemyindex and want to make the database
> configuration as flexible enough for developers that want to use or
> extend it.
> 
> When indexing an object you have attributes that are single and
> multivalued. The single valued attributes can be stored in a single
> table and multivalued attributes need a table per attribute due to the
> fact that most databases don't have a column type that is multivalued.
> 
> When indexing an object, one could query for utilities that implement
> IObjectMapper (or IRecordMapper) to index single valued attributes on a
> object and query for IKeywordMapper to index attributes that are
> multivalued. 
> 
> Utilities are really convenient here and it saves me the effort of
> building a specialised registry for mappers but I'm not sure that the
> above use case fits the semantics of a utility. But maybe it does?
> 

I feel quite comfortable now that utilities are a good fit here. They're
actually perfect for this use case and should help guard against a
proliferation of registries.

-- 
Roché Compaan
Upfront Systems                   http://www.upfrontsystems.co.za





More information about the Product-Developers mailing list