[Zope-dev] Context priority as an alternative to configuration directive overrides

Ross Patterson me at rpatterson.net
Sat Dec 4 15:21:02 EST 2010


Malthe Borch <mborch at gmail.com> writes:

> I always found configuration overrides (e.g. ZCML's <includeOverrides>
> directive) to be difficult to manage and hard to get right.
>
> How about an alternative where you can put a priority on a
> configuration context like so:
>
>   <adapter zcml:priority="100" ... />
>
> Default priority would be 0, traditional overrides get the maximum
> priority. ZTK components might then all be at the default priority,
> making it trivial to add a preferred component in a custom setup.
>
> If accompagnied by a sane amount of logging output, this system might
> facilitate plugging in components "for the rest of us".

I'd like to echo Malthe's concern here.  I've had many issues with this
as well.

Recently I had a conversation with someone or read something about using
add-on specific stacked component registries.  Would this be the best
way to solve these kind of problems?  Unfortunately I can't remember
where I head/read of this.

Ross



More information about the Zope-Dev mailing list