none
how to create a windows service Using Sync framework RRS feed

  • Question

  • guys,

    i want to create a windows service to monitor two locations and then apply one way sync. i need this happen in real time upon change of the contents of one folder.do i need to use a timer object in my service or does Sync framework has an event to register to automatically detect changes and apply sync again when session is created once in the beginning?

    in case of using timer, what's the good interval to detect changes? is it heavy on resources if i set for change detections every 10s? what's the best approach here?

    thanks

    SP

    Wednesday, March 24, 2010 5:18 AM

Answers

  • Hi SP,

    I dont think SyncFx has a concept of a continous synchronization. So synchronization should always be initiated.

    As for using timer, the interval would have to be largely dependent on how often the changes occur. The amount of changes detected and synchronized would have a bearing on the resource usage. If you set the timer too short and where there are no changes, then you may be wasting some processing cycles. If you set it too high, then you might have many changes detected. So you'll have to find the balance.

    hth,

    JuneT

     

    • Marked as answer by SP_TIO Wednesday, March 24, 2010 6:27 PM
    Wednesday, March 24, 2010 6:45 AM
    Moderator