[Zope3-dev] ObjectHub: Kill the plugins!

kapil thangavelu kvthan@wm.edu
Thu, 17 Oct 2002 22:40:43 -0700


On Thursday 17 October 2002 05:00 pm, Gary Poster wrote:
> [the fifth in a series of emails about the ObjectHub]
>
> I have been prototyping a client of the ObjectHub (the RelationManager
> discussed elsewhere) and have come to the conclusion that I don't like
> the idea of ObjectHub plugins at all. :-)
>
> The ObjectHub was supposed to hold plugins that did stuff like indexing
> and relating and so on.  They were merely subscribers to the ObjectHub
> that were conveniently placed.  In part this was because of the concept
> that we might have multiple ObjectHubs operating as different services.
> We have since simplified that concept so that now there is one ObjectHub
> service named, amazingly, "ObjectHub".
>
> As such, there is no longer any use for yet another piece of
> infrastructure--that is, making the ObjectHub a folder and specifying
> that only ObjectHub plugins can go in there and so on--when we can
> simply say "getService(context, 'ObjectHub')" and take advantage of the
> infrastructure we already have.  Things we thought of as plug-ins are
> merely subscribing clients: as such, they can be services themselves, or
> utilities, or whatever is appropriate.  With the elimination of the
> responsibility on a plug-in to handle translating removal of objects to
> unregistration in the ObjectHub that Chris, Steve, and I agreed upon
> today, the last reason I had for plugins disappeared.
>
> PROPOSAL: Eliminate the concept of ObjectHub plugins.  The ObjectHub has
> a simple contract: keep track of integer-to-path mapping, act as a
> transparent event channel, and generate hub events for its subscribers.
> That's it.  Any clients doing other tasks live elsewhere, using the
> ComponentArchitecture infrastructure, and have their own interfaces.

hmm.. so originally the objecthub was an object linking service and 
infrastructure for a catalog replacement, and now its just a 
linking/relationship service. but what replaces the plugins? it seems that 
the plugins are replaced by plugin indexes distributed along arbitrary 
locations of the object graph, that are registered as subscribers to hub 
events.

perhaps this object hub refactoring should say something about more explicit 
about what will replace the catalog infrastructure, to provide a common query 
interface to the distributed indexes? 

-kapil