On Thu, Aug 29, 2013 at 9:32 AM, giuseppe giorgio <[email protected]> wrote:
> i'm writing a SOAP web service that store in datastore some data and have > a service for retrieve stored data. Now i would that, after client invoked > the service and data are received correctly, delete it from datastore. I > was thinking to implement another service to be called after data recover > for notify to server that everithing it's ok and he can start to delete > data. There's another solution for do that without implement second > service, and make trasparent to user how server manage datastore? > The exact solution depends on if you want the user to acknowledge receipt of the data. If the user has to directly acknowledge the data transfer, then you have to implement the "another service to be called" so you can be sure that the user received the information. If you don't need a direct acknowledgement, then you can set up a task to automatically delete the data after a certain period of time. Set up a task to delete the data, use TaskOptions.countdownMillis ( https://developers.google.com/appengine/docs/java/javadoc/com/google/appengine/api/taskqueue/TaskOptions) to delay execution of the task by some period of time, then enqueue the task after you deliver the data to the client. If the client receives the data properly, then the datastore entities will be deleted soon after. If the client fails to receive the data, that's OK as well - they have a short period of time to reaccess and redownload the appropriate information. ----------------- -Vinny P Technology & Media Advisor Chicago, IL App Engine Code Samples: http://www.learntogoogleit.com -- You received this message because you are subscribed to the Google Groups "Google App Engine" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/google-appengine. For more options, visit https://groups.google.com/groups/opt_out.
