Hi, the big difference between memcache and "loading to memory" as you say is that the memcache is automatically replicated for you across the jvm automatically started by gae.
You can load yourself in memory by (for example) using a singleton as the anchor point for a data structure (probably a collection) keeping links to all your resources as objects (type=blob for image as example). In that case, your singleton will start empty in each new jvm and will have to be loaded on 1st use. The memcache is (to my knowledge) central memory: so it's as fast as your own memory structure. It just takes additional code to be accessed (i.e the google service) but in return offers the management of automatic copies, etc... regards didier On Mar 17, 3:20 am, Chun Guo <[email protected]> wrote: > Thanks for your advice. But I want to know the difference between loading > the records into the main memory and loading the records into the memory > cache. An other question is, both of the two approaches will consume a lot > of time, but the performance of the former is still questionable. > Expecting your further directions. Thanks for your attention! > Chun > > 2011/3/16 Didier Durand <[email protected]> > > > Hi, > > > In order to achieve your goal is the quota limit cannot be changed, > > may I suggest though that you still update your file to the datastore > > to serve them back to your clients. > > > You would not serve them from datastore but upload them into memcache > > (all at startup or 1 by 1 on 1st use) and serve them from this cache. > > Extremely fast and efficient. > > > As an intermediate, you can also try something lighter than JDO/JPA: > > either low-level api or 3rd party package like Objectify > > > regards > > > didier > > > On Mar 16, 10:24 am, Simon Knott <[email protected]> wrote: > > > Hi, > > > > The restrictions around your deployed application can be seen athttp:// > > code.google.com/appengine/docs/java/runtime.html > > > > The maximum size of your deployed WAR has to be 150MB, as far as I'm > > aware > > > it's not a quota which can be increased. > > > > Cheers, > > > Simon > > > -- > > You received this message because you are subscribed to the Google Groups > > "Google App Engine for Java" 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-java?hl=en. > > -- You received this message because you are subscribed to the Google Groups "Google App Engine for Java" 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-java?hl=en.
