I need to implement a background auto-save process that runs off a timer. I essentially keep a replicated copy of the data with different keys in the database and then remove it after a final save is done. The data entry process can take a long time and with a web/silverlight implementation and the such it is an important piece. I have a pre-defined key inplace at the creation of my objects for the new auto-save parent key so I can go and find the auto-save data if I need it.
Anyhow I thought there were two real options and I'm leaning to the first which seems the most simple:
1) Every x minutes I execute background commandBO and pass a copy of my BO and all associated BOLists. The command object does a simple database insert/update over the previous autoSave data and returns success / fail.
or
2) Every x minutes I set a 'IsAutoSaveFlag' call an async Save , reset the 'IsAutoSaveFlag' and let the dataportal handle things but I ignore whatever comes back.
The second option seems like lots of extra overhead etc but I'm wondering if anybody else implementing such a feature can recommend a reason why this may be a better choice.
Any other gotcha's out there? I suppose I need to deal with what happens if the autosave takes too long or doesn't come back etc.
Thanks
jack
Copyright (c) Marimer LLC