A further option involves using pull task queues. 1. Write a task to the pull queue for each item you wish to remember. 2. Have a queue reader run periodically**** - reading up to 1000 tasks at a time and writing the relevant information to the datastore.
****Although this sounds simple, you need to make sure that you run this doesn't run too often (and burn instance time with no benefit) or too infrequently (and fill up the queue because it never gets through all the tasks). Scaling is not done for you like it is with a push queue. Mat. On 5 October 2011 16:18, Simon Knott <[email protected]> wrote: > I believe you have a couple of options: > > Change your task queue configuration, so that it can't run updates > concurrently and slow the task queue down so that it doesn't go over the > desired rate of 1 per second. Docs for this configuration can be found at > http://code.google.com/appengine/docs/python/config/queue.html - Ikai also > drew a nice diagram at http://twitpic.com/3y5814! This route may lead to a > backlog of data, if your updates are frequent. > Alternatively you can write the data to Memcache, as you suggested, and have > the cron job periodically write the data into the datastore. This route can > lead to dataloss, as if MemCache is flushed you will lose any updates that > were pending storage. > > -- > You received this message because you are subscribed to the Google Groups > "Google App Engine" group. > To view this discussion on the web visit > https://groups.google.com/d/msg/google-appengine/-/-dejKvvC6wAJ. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]. > For more options, visit this group at > http://groups.google.com/group/google-appengine?hl=en. > -- You received this message because you are subscribed to the Google Groups "Google App Engine" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en.
