[ZODB-Dev] Replicating data over disconnected servers.

Christian Robottom Reis kiko@async.com.br
Fri, 25 May 2001 15:07:48 -0300 (BRT)


On Thu, 24 May 2001, Tim Cook wrote:

> May I guess that an export/import solution doesn't work for your
> situation?
> Or are you attempting something more dynamic?

You mean a full export/import of the whole database? Hmmmm. Well, the
problem is mainly that there is data (objects) on side A and on side B,
and only part of that data needs to be updated. There are semantics on
these updates that I have to preserve, and that's why I'm wondering what
the right solution is. That, and me not understanding very well what ZODB
does with the actual id()s of the objects it's restoring -- I must assume
there's some reference rewriting done on-the-fly, but Jim hasn't said so
yet.

> Maybe some insight on how you designed your site would help.

Well, it's not a site, to start off with. It's a distributed, open source,
Point of Sales/Enterprise solution with commerce (not e-commerce, now) as
it's main focus. There is a central server that sits in an office that
syncronizes with many stores periodically; these run their own servers and
are busy capturing sales objects and updating inventory objects.

Now the inventory object must be maintained sincronized with the main
database, which means updates must flow to and from that database to/from
the stores. Since these updates could conflict, there has to be conflict
resolution and so forth. _Apart from that_, my object contain references
to many other objects, so closure has to kept in the sense that these
references shouldn't break. Object must preserve referential integrity
when moving from store to server.

The other objects (unique -- such as sales) are only copied over to the
central server, but they also have to work with closure on that operation.
That's my main point of doubt; how to maintain that. I would like to think
ZEO solved the problem, but I can't see how.

Makes me long for the old RDBMS days, where I just issued an INSERT and a
DELETE (okay, maybe some CASCADEs) and that was it. Oops, I uttered SQL in
a OODB mailing list. :)

Take care,
--
/\/\ Christian Reis, Senior Engineer, Async Open Source, Brazil
~\/~ http://async.com.br/~kiko/ | [+55 16] 274 4311