[Zope3-dev] Re: Creating new objects in a package

Stephan Richter srichter at cosmos.phy.tufts.edu
Thu Sep 23 13:27:19 EDT 2004


On Thursday 23 September 2004 12:35, Philipp von Weitershausen wrote:
> Peter Mayne wrote:
> > I'm using the MessageBoard package to experiment with.
> >
> > I'd like to pre-load some messages from a package script, but after
> > reading various documentation (including the Zope3 book and tutorials) I
> > can't figure out how to do something as basic as create and save new
> > objects.
>
> You could write an event subscriber that subscribes to
> IDatabaseOpenedEvent and then operates on the database directly. But I
> wouldn't do that.
>
> I would do it much simpler and write (if not already provided) XML-RPC
> or WebDAV views/filerepresentation adapters and bulk-load objects using
> either a custom XML-RPC client script written in Python or whatever, or
> even a simple WebDAV or FTP client.

I would probably use XML-RPC; it is the easiest to do.

You could also use an XML-File import/export tool to do the upload of data. I 
have such code in the bug tracker application.

Regards,
Stephan
-- 
Stephan Richter
CBU Physics & Chemistry (B.S.) / Tufts Physics (Ph.D. student)
Web2k - Web Software Design, Development and Training


More information about the Zope3-dev mailing list