| > CRDTs don't _ensure_ ops are commutative (and associative, and idempotent) but rather they _require_ that ops are commutative (and associative, and idempotent) I disagree. You can create a CRDT flavor of data structure whose ops are not commutative. For example, a Set's add and delete operations. These are not commutative. You cannot switch the order of the ops for meaningfully processing them. However, you can create a CRDT Set. You do that by adding metadata to the ops, and having the instances always process them in the only order that makes sense even if such instances receive the ops in a different order. In that sense, you are "ensuring" ops are behaving like they are commutative and not "requiring" them to be so. > it's definitely not the case that any data structure is a CRDT I could have worded my statement better. I meant any data structure that has the aforementioned duality property is a CRDT. Not that any data structure unconditionally can be translated into a CRDT. > an important "eureka" observation about CRDTs is that the op-based model is theoretical, I do not understand your statement. Perhaps you could elaborate. My understanding is that a CRDT is op-based or state-based depending on what is "communicated" between the instances. If ops are communicated, then it is op-based CRDT, whereas if states (or delta-states) are communicated, then it is state-based. At least in that sense, op-based model is NOT theoretical. Perhaps you have a different point in mind that I fail to observe. |
> I disagree. You can create a CRDT flavor of data structure whose ops are not commutative
i think it's important to reiterate (for other third-party readers) that this is factually incorrect
a data structure with operations that are not commutative (or associative or idempotent) is not a (state-based) crdt by definition