How to resolve logged conflicts with simple providers? RRS feed

  • Question

  • I've been trying different conflict resolution policies with my simple providers. For far all resolution methods worked except one: conflict resolution policy is set to "application defined" and in my custom resolver i'm setting resolution action to "SaveConflict". There are a series of questions associated with this:

    1. Do simple providers support logging conflicts? If so are they using in-memory conflict log?

    2. How to get access to this log?

    3. How to resolve the conflicts? According to document what I need to do are:

    1. Increments the tick count of the replica.

    2. Updates the change version of the item or change unit to reflect that the change is made by the local replica with the updated tick count.

    3. Combines the knowledge of the replica with the knowledge of the conflict by using Combine (for managed code) or Union (for unmanaged code), and saves the combined knowledge as the new knowledge of the replica.

    4. Applies the change data to the replica.

    5. Removes the conflict from the conflict log.

    But I'm stuck at first step as I don't know how to increase tick count of a replica (I don't have clues for the rest of steps either).


    Thursday, April 1, 2010 12:28 AM


All replies

  • have you looked at this? http://social.microsoft.com/Forums/en-US/syncdevdiscussions/thread/d0db98b7-c246-46eb-b1d5-b4a64a1e8fab

    might be similar to what you were trying to accomplish.

    Thursday, April 1, 2010 12:54 AM
  • Hi JuneT:

    That's very useful post, I'll check it out. However in one of the responses Patric S. Lee commented:

    "Why do you need to use this MemoryConflictLog? Using this with SimpleProvider is not a supported scenario as this might interfere with internal SimpleProvider logics."

    This worries me. Am I not supposed to use MemeoryConflictLog? My scenarios is to allow user to decide whether to resolve certain conflicts and/or use different means to resolve particular conflicts. Are there any alternatives to using logged conflicts?

    Also, is there a sample to implement this? Thank you!

    Thursday, April 1, 2010 1:20 AM
  • I always thought if the API is exposed publicly, then it should be ok to use it unless otherwise stated :)

    but i do agree with you, the statement is  worrisome. So I'll leave it to Patrick to clarify.

    Do you need to resolve the conflicts after the sync? or can you do the user prompting interactively while applying the change?

    Thursday, April 1, 2010 1:32 AM
  • Thank you JuneT, i'll follow up in the other post.
    Thursday, April 1, 2010 1:37 AM