I'm working on a multi-platform "occassionally connected" app. Each instance of the app stores a "cache" of the data that it retrieves from the cloud, which has the authoritative datastore. So on start-up the app would check if its cache is out of date, and if so download the delta from the cloud. This is certainly do-able in WP7. What I don't know how to achieve is to send any changes made by the app back to the cloud. When the user exits the app, in iOS or Android, I would launch a background task to transmit the delta back to the cloud, but with wp7, without that background functionality, I would have to transmit on close, and I could not guarantee that the transmission would finish before the OS killed my app. Is this just not achievable on WP7 today?
A couple of options here which you could apply independently or both of.
You could do a more chatty conversation with your server.. ie communicate changes as they are accepted by the user.
You could also have a background process runing while your app is running that sends changes up at periodic intervals.
There may be times when the changes aren't sent up and the app is no longer running. These would be picked up next time the app is running.
I suppose you could describe this as a best effort basis.
精彩评论