[Product-Developers] Private messaging between members

Guido Stevens guido.stevens at cosent.net
Mon Sep 2 08:35:56 UTC 2013


On 09/02/2013 08:05 AM, Carsten Senger wrote:
> - ZODB / BTrees
>   - seperate ZODB mounted somewhere

The Plonesocial pattern of storing messages in a BTree portal tool means
you can postpone the choice of a separate ZODB mount point to deployment
configuration time. Doesn't impact the code.

> - Store the messages in an RDBMS

By having a single accessor (your portal tool API) on all the messages
you can also later swap out the implementation into an RDBMS powered
backend. You retain the option.

> For simplicity reasons we would like to keep the messages in the ZODB.
> Has someone experience with a similar system and the performance of
> BTrees? Is there a product with similar storage requirements that we can
> look at?

The core performance bottleneck I ran into when testing Plonesocial, is
performing more than a dozen concurrent transactions against the ZODB.
For this reason I developed a batching mechanism which stores new
messages into a in-memory queue and flushes everything into persistence
once per second. That way you can handle a very high number of database
inserts with only one transaction, bypassing the commit bottleneck.

The code doing that is already in a separate batching class. With a few
small tweaks I can refactor that into a generically re-usable mixin
class or adapter you could use in your project.

But, taking this one step further, I would love to have this
functionality as part of Plonesocial... If we have a separate component
e.g. plonesocial.messaging you don't have to pull in the rest of
plonesocial.* into your project. While on the other hand I can take care
of integrating this functionality with the rest of the Plonesocial
suite. Please contact me off-list if you'd like to explore this route.

:*CU#
-- 
    Guido Stevens  |  +31.43.3618933  |  http://cosent.nl

    s o c i a l   k n o w l e d g e   t e c h n o l o g y



More information about the Product-Developers mailing list