Sync Files Over Tcp, Microsoft Sync Framework RRS feed

  • Question

  • Ok, I create program using sync framework with custom file sync provider:

     public class RemoteSyncFileProvider : FullEnumerationSimpleSyncProvider, IDisposable, ISimpleSyncProviderConstraintConflictResolver

    I replaced Local functions like File.Copy to anologs what make changes on remote file system

    And Its works fine.

    If on remote file system some file deleted or on local computer metadata files corrupted or deleted. There no way that i can update local metadata with information about remote file system . I need To delete all files in remote fs and start syncronisation, if not - it crash with message about same data already exist in storage...(The simple provider found an item in the metadata store with the same identity fields as the current item .)

    So i need a tool what can update state about remote and local file system in metadata files, any ideas?

    All my problems within metadata files.

    Thursday, August 26, 2010 8:23 AM

All replies

  • Hi, cerriun.

    Can you please elaborate more on your case? I am not sure I understand your particular scenario here. The error message you see means you are probably trying to insert an item which already exists in the metadata store.


    Thursday, September 2, 2010 7:01 PM
  • I have come across a similar problem which I've not fully solved yet.

    I will try to simplify it to the core issue:

    I have some files in the client replica, and a subset of those files on the server replica. The call to enumerate the items on the server returns what appears to be the correct list of files on the server but the synchronisation orchestrator doesn't seem to be aware that these files are the same as those on the client, so tries uploading the files again, rather than only uploading the files that aren't already on the server - this then causes the orchestrator to try and insert a row with the same filename as an existing row into the server metadata store.

    A workaround is to delete the metadata stores, and the files from the server, and start again.

    Wednesday, September 29, 2010 4:01 PM
  • Hey,

    In your scenario where server has subset of files as those on client, did server get those file through synchronization by SyncFX or not? If yes, the metadata stores should have the corrent info. Otherwise, those would be treated as duplicate items.



    Ann Tang
    Wednesday, September 29, 2010 5:08 PM
  • The server got the files through the SyncFX but the metadata store was then deleted. What would you suggest in the situation where the metadata stores (both held on the client) are lost?
    Thursday, September 30, 2010 12:20 PM