[Zope] getting a unique object id

Dieter Maurer dieter at handshake.de
Fri Mar 30 17:37:03 EDT 2007


David Bear wrote at 2007-3-29 17:50 -0700:
> ...
>My thinking was to use feedparser, then grab the set of object
>attributes for the item from zope. Then, grab the actual document the
>feed pointed to and save it. When naming the document that I store
>locally, I was looking for a simple way to map the zope objectId to
>the file name hoping it would be unique.

What do you mean be "the zope objectId"?

Persistent objects have an "_p_oid" attribute. It is unique
within the ZODB (storage) the object is stored in.

I cannot tell whether or not your RSS feed is represented by a persistent
object. If it is, you can probably use "_p_oid" as your cache id.



-- 
Dieter


More information about the Zope mailing list