And, I should add, this works perfecty (and quickly) from the development server's datastore.
On Apr 29, 8:31 am, tayknight <taykni...@gmail.com> wrote: > I have a problem. I'm getting datastore timeouts when doing reads. The > code finished about 5% of the time. The code looks like: > > alerts = Alert.all().filter('expires >= ', datetime.datetime.now()) > # ge active alerts > for alert in alerts: > #get the db.Keys from the ListProperty > zones = ZoneMaster.get(alert.zones) > for zone in zones: > if zone: > #get the users for this zone > if zone.siteusers: > us = SiteUser.get(zone.siteusers) > for u in us: > if u: > self.response.out.write(u.name + '<br />') > > The Model looks like: > class Alert(db.Model): > effective = db.DateTimeProperty() > expires = db.DateTimeProperty() > zones = db.ListProperty(db.Key) > > class ZoneMaster(db.Model): > siteusers = db.ListProperty(db.Key) > > class SiteUser(db.Model): > name = db.StringProperty() > zone = db.ReferenceProperty(ZoneMaster) > > This code is repeatably timing out with a "Timeout: datastore timeout: > operation took too long." error. > I'm not doing any writes. All the reads are by key (that come from a > ListProperty). Why would this be timing out? > > 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 google-appengine@googlegroups.com To unsubscribe from this group, send email to google-appengine+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/google-appengine?hl=en -~----------~----~----~----~------~----~------~--~---