locked
Sync Framework 2.1: How is retention handled? RRS feed

  • Question

  • Hello There,

    I am in the process of upgrading a WPF application to use sync framework 2.1.

    As part of this I am using the new, far simpler API for creating scopes etc.

    The tutorials on MSDN that I have seen thus far do not mention retention and how it is handled. This used to be handled by the server itself, as SQL Server Change Tracking was used. This is no longer the case. So, how should retention be handled and old meta data cleaned up?

    Thanks

    Tuesday, November 9, 2010 11:24 AM

Answers

  • if you're using the collaboration providers (SqlSyncProvider/SqlCeSyncProvider), you can set the SqlSyncStoreMetadataCleanup.RetentionDays/SqlCeSyncStoreMetadataCleanup.RetentionInDays property and call PerformCleanup to actually do the clean up.
    • Proposed as answer by JuneT Friday, November 19, 2010 1:11 AM
    • Marked as answer by Warpkid Monday, December 13, 2010 1:06 PM
    Tuesday, November 9, 2010 3:51 PM

All replies

  • if you're using the collaboration providers (SqlSyncProvider/SqlCeSyncProvider), you can set the SqlSyncStoreMetadataCleanup.RetentionDays/SqlCeSyncStoreMetadataCleanup.RetentionInDays property and call PerformCleanup to actually do the clean up.
    • Proposed as answer by JuneT Friday, November 19, 2010 1:11 AM
    • Marked as answer by Warpkid Monday, December 13, 2010 1:06 PM
    Tuesday, November 9, 2010 3:51 PM
  • Thanks,

    So this is something that I would have to call every now and again to clean up the database?

    Or should I make the call from within the client software every time someone syncs?

     

    Thanks again

    Monday, December 13, 2010 1:07 PM
  • depends on number and frequency of changes you sync... doesnt hurt to run it every now and then though...
    Monday, December 13, 2010 3:13 PM