Chasing consistency

Stumbled upon statebox while looking for answer on how to manage a set of members (keys in other buckets) with regards to riak`s eventual consistency. I like the approach because it solves the resolution for the generic case rather than doing something custom for each possible conflict in the application. It does this by putting some restrictions on what operations you may do on the data, most set like operations are cool.

One of the core concepts is that every operation is idempotent, and this is where it breaks down for me as I explicitly don't want some operations to be repeatable. Removing a member from the set in my use case implies it will be added to a set stored at another key. If I could remove it twice it could be added to two different sets, and that can't happen.

I'm currently looking into doing a variation where instead of using only repeatable operations I only use reversible operations. E.g you can't add something to a set that is already in there as that operation would not be possible to reverse without knowing the previous state already.