@@ -24,8 +24,34 @@ func TestMultiActorConflictCreate(t *testing.T) {
2424 docID := getDocID (t )
2525 docVersion := createConflictingDocs (t , collectionName , docID , topology )
2626 topology .StartReplications ()
27- waitForVersionAndBody (t , collectionName , docID , docVersion , topology )
28-
27+ // Can not assert on full HLV here. CV should converge, but CBL actors can have PV that does not match that of the other peers.
28+ // + - - - - - - + +- - - - - - -+
29+ // ' cluster A ' ' cluster B '
30+ // ' +---------+ ' ' +---------+ '
31+ // ' | cbs1 | ' <--> ' | cbs2 | '
32+ // ' +---------+ ' ' +---------+ '
33+ // ' +---------+ ' ' +---------+ '
34+ // ' | sg1 | ' ' | sg2 | '
35+ // ' +---------+ ' ' +---------+ '
36+ // + - - - - - - + +- - - - - - -+
37+ // ^ ^
38+ // | |
39+ // | |
40+ // v v
41+ // +---------+ +---------+
42+ // | cbl1 | | cbl2 |
43+ // +---------+ +---------+
44+ // Couchbase Server, since conflict resolution in XDCR will overwrite the HLV.
45+ // 1. sg1 creates unique document cv: 1@rosmar1
46+ // 2. sg2 creates unique document cv: 2@rosmar2
47+ // 3. cbl1 pulls 1@rosmar1
48+ // 4. cbl2 pull 2@rosmar2
49+ // 5. cbs1 pulls 2@rosmar2, overwriting cv:1@rosmar1
50+ // 6. cbl1 pulls 2@rosmar2, creating cv: 2@rosmar2, pv:1@rosmar1 overwriting
51+ // Final state:
52+ // - cv:2@rosmar2 on cbs1, cbs2, cbl2
53+ // - cv:2@rosmar2, pv:1@rosmar1 on cbl1
54+ waitForCVAndBody (t , collectionName , docID , docVersion , topology )
2955 })
3056 }
3157}
0 commit comments