[Zope] newbie questions about packages, external methods and persistence

Gregor McEwan mcewan@dstc.edu.au
Tue, 2 Nov 1999 13:02:26 +1000


Hi,

I have 3 questions that are (hopefully) easy for someone with Zope
experience.

1)  What's the best way to access a python package from Zope?
My current state of knowledge would suggest that an external method or set
of external methods would be the best way.  However, does that mean that for
each external method that accesses one of the methods in my class, I have to
create a new instance of the class?  Is there some way to keep a reference
to a class as a Zope object so that I can use it in different DTML documents
in the same folder?

2)  What are the issues with using ZODB filestore persistence in a package
that is accessed through Zope?
My package uses the filestore persistence and works fine when used by
itself.  When I try to access it through a web page using an external method
I get an IO error saying that permission is denied on "Entity.fs.lock"
("Entity.fs" is the filename I specified to store the persistent objects).
Do I have to use a different type of persistence?  Or is there something
else that I've done incorrectly?

3)  There is an example of an application that seems to be very similar to
what I want to do in the document "A Technical Introduction to Object
Publishing with Zope".  I realise that this document is dated but is the
information in this example still valid?  If not, could someone tell me, in
general terms, what the new approach should be to this kind of problem?  How
does the Zope management interface fit into this?

I realise that these are potentially big questions (especially the third),
but I would be very grateful if someone could even just point me in the
right direction or give a couple of hints :-)

Thanks,
-------------------------------------------------------------
Gregor McEwan
Research Scientist
DSTC Pty Ltd
Level 7, GP South
University of Queensland 4072, Australia
Phone: +61 7 3365 4310
Fax: +61 7 3365 4311
Email: mcewan@dstc.edu.au
"To know the road ahead
               Ask those coming back."  Chinese Proverb