开发者

Sync Services downloads data, but doesn't update local SDF file

I've setup a local cache of data in my ASP.NET app. I've got the app reading/writing to the local SDF file using the Entity framework.

When I issue the sync command:

DataCacheSyncAg开发者_如何学JAVAent syncAgent = new DataCacheSyncAgent();
Microsoft.Synchronization.Data.SyncStatistics syncStats = syncAgent.Synchronize();

The sync agent pulls down all the changes that are on the server. In fact, I can even see those changes reflected in my app.

However, if I browse the local .SDF file, the data changes are not there. Worse yet, if I restart my app, the changes that were downloaded are lost.

It's like somehow the changes get saved in RAM, and the Entity framework queries those instead of the .SDF file.

Is there something else I'm supposed to do to actually "commit" the changes to disk?


Ok, problem was simply that my local app file was being copied to the debug folder with each run.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜