Thats a good point, Thanks Kenneth for clarifying it! On 19 November 2010 09:32, Kenneth <[email protected]> wrote:
> For people who are all excited about the long running tasks in 1.4.0, > be aware of a minor issue that queries still can't live more than 30 > seconds (although this is no doubt subject to change) > > You can't do this for more than 30 seconds (java devs excuse the > python): > > for item in Model.all(): > dosomething > > It will still timeout after 30 seconds if you haven't gotten through > Model. Note that this pattern is highly inefficient anyhow as it only > grabs 20 rows at a time before doing another rpc. > > You need to do Model.all().fetch(x), set x so you don't run out of > memory and wrap that in an outer loop that uses cursors to re-execute > the query. > > For me it was simpler just to keep the old 30 second logic in place. > > -- > 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.
