Uploaded image for project: 'Couchbase Lite'
  1. Couchbase Lite
  2. CBL-634

Revision flags get cleared while saving resolved document in Java

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • Blocker
    • Resolution: Fixed
    • 2.7.0
    • 2.7.0
    • Java-Android
    • Security Level: Public
    • None

    Description

      Java clears the revision flags in its saveResolvedDocument function
      CBL / SG Version: Android - 2.7.0-255 , iOS - 2.7.0-99, SGW - 2.7.0-165
      *Steps to Reproduce: *
      1..Net client as user1 created new list and task with attachment and shared with user2(Android client)
      2. Both clients went offline.
      3. User1 updated image and marked as complete
      4. user2 edited the name of the same task with new name
      5. both clients came online

      Steps from Jim from his point of view :
      Start with a synced document between two devices at the same rev
      Go offline with both
      Make at least one change on device 1 with no blob change
      Make more than one change on device 2 with a blob change
      Bring device 1 online, so it syncs first
      Bring device 2 online, so its sync will get 409
      SG sends device 2 rev 7 which will cause a pull conflict
      Java conflict resolution handler accidentally clears the attachment flag on the new revision
      LiteCore doesn't send the _attachments dictionary since the rev doesn't have the attachment flag

      Actual Result:
      6. User1 and user2 had the task marked as complete, but has old image which attached while created new task at step 1

      Expected Result: user1 and user2 should have image updated and mark the task 'checked' as user1 wins with default conflict resolution

      Note : Did not provide any logs as we tracked down the issue

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            Build couchbase-lite-java-2.7.0-94 contains couchbase-lite-java-ee commit 812eaae with commit message:
            CBL-634: losing doc flags after conflict resolution

            build-team Couchbase Build Team added a comment - Build couchbase-lite-java-2.7.0-94 contains couchbase-lite-java-ee commit 812eaae with commit message: CBL-634 : losing doc flags after conflict resolution

            Build couchbase-lite-android-2.7.0-261 contains couchbase-lite-java-ee commit d351bc8 with commit message:
            Merge pull request #18 from couchbaselabs/hotfix/android/CBL-634

            build-team Couchbase Build Team added a comment - Build couchbase-lite-android-2.7.0-261 contains couchbase-lite-java-ee commit d351bc8 with commit message: Merge pull request #18 from couchbaselabs/hotfix/android/ CBL-634

            Build couchbase-lite-android-2.7.0-261 contains couchbase-lite-java-ee commit 024304d with commit message:
            CBL-634: losing doc flags after conflict resolution

            build-team Couchbase Build Team added a comment - Build couchbase-lite-android-2.7.0-261 contains couchbase-lite-java-ee commit 024304d with commit message: CBL-634 : losing doc flags after conflict resolution
            blake.meike Blake Meike added a comment -

            Sridevi Saragadam Can you please confirm that this can be closed?

            blake.meike Blake Meike added a comment - Sridevi Saragadam Can you please confirm that this can be closed?

            looks like this is duplicate of CBL-623, yes we can close this

            sridevi.saragadam Sridevi Saragadam added a comment - looks like this is duplicate of CBL-623 , yes we can close this

            People

              sridevi.saragadam Sridevi Saragadam
              sridevi.saragadam Sridevi Saragadam
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes

                  PagerDuty