[Twisted-Python] Advice Request: Under what circumstances should I use AMP's Command Response field?

Laurens Van Houtven _ at lvh.io
Wed Aug 21 06:28:34 MDT 2013


Hi Burak,


I think you're doing fine. Distributed systems are just kind of hard :-)

It sounds like your fundamentally building an eventually consistent
distributed database. We have a few of those already: it might be
significantly less work to just use one of them. I suppose it depends why
you're trying to make it distributed. Is this about reliability in the face
of e.g. hardware failure, or is this about being able to disseminate data
when someone tries to stop you from doing so? Are you trying to protect
against byzantine failures too?

That said, you might want to consider how you communicate posts. Six months
worth of posts is a lot. Even with ten posts per day, you'd end up with
~10*30*6 = 1800 hash values. The digest size of BLAKE2 is variable, but if
you're using 512 bit digests, that's 64 bytes, or 112.5 kibibytes for the
whole thing. That's probably more than you want to send in a single message.

While you can't rely on synchronized clocks (in the wall-clock time sense)
in a distributed system, you *can* rely on timestamps of your immutable
messages. You could send only message id's in the preceding time window,
for example. You can use hash chains to guarantee that the boards share the
same history.

cheers
lvh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: </pipermail/twisted-python/attachments/20130821/dde49069/attachment-0002.html>


More information about the Twisted-Python mailing list