[Grok-dev] Re: STORM howto

Christian Klinger cklinger at novareto.de
Fri Mar 14 05:16:01 EDT 2008

Sebastian Ware schrieb:
> Do I add nva.stormcontainer in setup.py in order to fetch this egg? I 
> would like to try it.

Yes this should do it. Hopefully...

> Also, is there any way I can control the commits? I am basically doing:
> for obj in objlist:
>     ormContainer['id'] = obj

In the stormcontainer there is a __setitem__ which is responsible for 
the insert.

     def __setitem__(self, name, item):
         store = getUtility(IZStorm).get(self.getStoreUtilityName())

The transaction.commit() fires also an rdb.commit. This means on every 
insert there is a commit.

But maybe it is possible to delete the transaction.commit() in 
__setitem__, and rely on zopes transaction.commit.?

HTH Christian
> And, I only want 1 commit for all the inserts.
> Mvh Sebastian
> 14 mar 2008 kl. 09.39 skrev Christian Klinger:
>> Hi,
>> I will first introduce myself a little bit:
>> I ´m working with zope since 3-4 years. I started with 
>> TTW-Programming, Plone/Archetypes and now im looking forward into 
>> GROK/Z3.
>>> Hey,
>>> Christian (Klinger), Sebastian, and Brandon too:
>>> I just started a discussion on the Storm mailing list with some 
>>> questions. I'm exploring whether Storm could make for a good default 
>>> relational database integration layer for Grok.
>> Yes i have seen your post. A very good starting point for discussions...
>> As some of you know i worked on piece of software called 
>> nva.stormcontainer. The goal of this container is do the same as a 
>> normal grok.Container but write/read. the objects from an rdb instead of
>> zodb.
>> I have a first release on pypi:
>> http://pypi.python.org/pypi/nva.stormcontainer/0.2
>> dobee (Bernd Dorn) from lovely.systems and Gustavo Niemeyer gave me some
>> great feedback on the stormcontainer.
>> http://comments.gmane.org/gmane.comp.python.storm/459
>> I ´ve in my local repository a new version of this container with 
>> nearly all suggestions from Bernd.
>> Here are the reasons why i take storm instead of sqlalchemy:
>> -- out of the box Zope-Integration
>> -- very easy and understandable
>> I hope i can join the Grokkerdam sprint to work on these topics.
>> Christian
>> _______________________________________________
>> Grok-dev mailing list
>> Grok-dev at zope.org
>> http://mail.zope.org/mailman/listinfo/grok-dev

More information about the Grok-dev mailing list