Thanks, Nick. It looks like the task queue might work for me. I am doing an ajaxy thing; the user input messages are stored to the datastore, where they are processed by my task queue every 1-4 seconds. That task will store the response to each user in the datastore, where the user can retrieve it with an ajax poll. I am not sure how well it's going to scale. Each user message is stored as an individual datastore entry, so the task queue could conceivably be querying many messages. Each response, at the moment, is also an individual datastore entry. I can probably make all the responses into one large response datastore/memcache object.
On Sun, Jun 6, 2010 at 10:41 PM, Nickolas Daskalou <[email protected]>wrote: > You can add tasks to the Task Queue to overcome cron's 1-minute-minimum > time interval by eg. creating a task that adds itself back into the Task > Queue once it's completed (with an ETA of 1-4 seconds). > > However, is this some sort of AJAX-ie thing you're doing? Ie., will the > processing of user input be a one-off thing to kick-start asynchronous > "output" (and subsequent output every 1-4 seconds), or will there be > user/browser input every 1-4 seconds that you need to respond to > synchronously? If the latter, then right now your only option is polling. > The good news is that Google are planning to release Comet-like features in > the not too distant future. You can find out about it by following the links > in Nick Johnson's latest blog post: > > > http://blog.notdot.net/2010/06/Google-I-O-playlist-day-3-What-s-hot-in-Java-for-App-Engine > > Nick > > > On 7 June 2010 12:12, Ryan <[email protected]> wrote: > >> I'd like to execute a short script that processes user input and >> creates output every 1-4 seconds. I can't use a cron, because I can >> at most execute this once every 1 minute. Is there some way to do >> this without requiring that something polls my app? >> >> Thanks. >> >> -- >> 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]<google-appengine%[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]<google-appengine%[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.
