询问者
Microsoft Sync Framework 提高文件同步速度

问题
全部回复
-
-
Hi,
硬件的IO是有一定瓶颈期,在到达这个瓶颈期,我们最大化的使用CPU资源,用多线程,或者线程池.
Best Regards,
Hart
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click HERE to participate the survey. -
两个文件夹A、B之间同步的步骤如下:
1.创建FileSyncProvider 对象来指向A文件夹.,再创建FileSyncProvider 对象来指向B文件夹
2.然后使用 SyncOrchestrator 对像.的源属性绑定A的provider对象,目标对象绑定B的provider对象。
3.调用SyncOrchestrator 对象的Synchronize方法去同步A、B文件夹.
如果使用多线程,该如何调整以上代码?
-
建议你把原来代码放到一个Windows Service里边,其中做一个简单的WinForm界面,报告进度。
等到全部同步完成,才弹出对话框,告知全部完成。
ASP.NET Forum
StackOverFlow
FreeRice Donate
Issues to report
-
Hi,
硬件的IO是有一定瓶颈期,在到达这个瓶颈期,我们最大化的使用CPU资源,用多线程,或者线程池.
Best Regards,
Hart
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click HERE to participate the survey.两个文件夹A、B之间同步的步骤如下:
1.创建FileSyncProvider 对象来指向A文件夹.,再创建FileSyncProvider 对象来指向B文件夹
2.然后使用 SyncOrchestrator 对像.的源属性绑定A的provider对象,目标对象绑定B的provider对象。
3.调用SyncOrchestrator 对象的Synchronize方法去同步A、B文件夹.
如果使用多线程,该如何调整以上代码?
-
Hi,
如果文件夹下面的子文件夹比较多,你就可以用多线程来做,这样效率,就会提上了。 中间可以用event来触发。
Best Regards,
Hart
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place. Click HERE to participate the survey.