[Zope3-dev] DC Contributors

Fred L. Drake, Jr. fred at zope.com
Tue Dec 2 13:36:07 EST 2003


Garrett Smith writes:
 > I'd like to start capturing the principal who last modified an object. 
 > My thinking is to use the pattern in
 > 
 >     zope/app/dublincore/creatorannotator.py
 > 
 > and apply it to the DC 'contributors' element. I.e. when an object is 
 > modified (signalled by a published ObjectModifiedEvent) the principal 
 > returned by getSecurityManager().getPrincipal() would be added to the 
 > object's dublin core annotations as a contributor.
 > 
 > I see a few problems with this:
 > 
 > - The number of contributors over time could become very large.

Not sure that's important if this information is important.  Perhaps
you'd like to present a use case for the modification history?

 > - The value of DC contrtributors would not really be the list of 
 > contributors -- only the set of principals who modified the object at 
 > some point. E.g. there could be contributors who haven't edited the 
 > object yet, expired contributors, etc.

This is where I have a problem with it.  The
Zope-object-modification-history (or
Zope-object-list-of-modifying-principals, or whatever this is) just
isn't the same as the contributors list.  Contributors may not be site
users of any sort, or may include different people interacting as the
anonymous user (such as a wiki page that allows non-authenticated
modification).

I think the modification trail (even if abbreviated to "who changed
this") is different from the Dublin Core "Contributor" element.  If
valuable, this should be kept as a separate bit of metadata.  This is
especially important if the Zope object is a reference to some
external resource not managed in Zope (possibly not in any digital
form) and the DC metadata is being used to describe the external
object.

 > Another approach might be to only store the principal who *last* 
 > modified the object -- contributors would only contain one principal 
 > under nornmal circumstances.

That deals with size, but that can be done in other ways if it's a
matter of avoiding loading much persistent data.

 > I'm not perfectly happy with using the Contributors element this way, 
 > but I think it's essential that we capture 'modified by' info in 
 > addition to capturing 'created by' info. Since it looks like DC is the 
 > model for this sort of thing in Zope 3, Contributors is the right choice.

If this isn't a direct match for a Dublin Core element, let's not
overload it.  We have a component architecture and an annotation model
that let's us be very flexible; let's not waste it by fudging the use
of DC elements.  Our current use is already pretty questionable in my
book, simply because there can be multiple things described, and the
way we use the DC data isn't clearly defined.

I think we should have DC data for the Zope object distinct from any
metadata we're using the system to store, and I don't think this kind
of usage pattern is very clearly discussed anywhere.  I wish I had
more time to work on this, but don't foresee that in the near future.

 > Thoughts?

Regret asking?  ;-)


  -Fred

-- 
Fred L. Drake, Jr.  <fred at zope.com>
PythonLabs at Zope Corporation



More information about the Zope3-dev mailing list