With Method 2 the datastore can do the fetches in parallel. The GAE team recommends method 2 for speed.
2009/1/14 boson <[email protected]>: > > What is the performance difference we should expect (if any) between: > > 1. N x Model.get(key) > i.e. making N calls to Model.get with various keys > > vs. > > 2. Model.get([key1, ... keyN]) > i.e. making a single call to Model.get with an array of N keys > > > I'm trying to optimize out some CPU warnings. Will changing #1 into > #2 make a difference? > > > --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
