> If you cache is in memory (ie not stored memcache or the datastore)
> then if the instance holding the hashmap is shutdown from inactivity
> (oftern in less than two minutes) you will lose everything.
I didn't realize inactive apps got shut down. That seems to be the
root of the problem.
> When you say "remote retrieval takes 6-7 secs" I assume you don't mean from the datastore?
6-7 seconds is the amount of time for my web brower to receive a
response to its request for an object from the server. It seems that
all that time is spent re-starting the app. Once the app is re-
started, retrieving and de-serializing (I'm storing my objects as
serialized blobs due to datanucleus choking on some generic classes)
an object from the datastore takes around 200ms. For example, getting
2 objects from datastore after inactive interval: first takes 6-7
seconds, second takes 200ms.
So... is there any way to keep my app from being inactivated? I could
schedule a cron job to ping my app every couple minutes. Is that the
recommended solution?
Oddly enough, looking at the cron documentation, their first example
entry is:
<cron>
<url>/recache</url>
<description>Repopulate the cache every 2 minutes</description>
<schedule>every 2 minutes</schedule>
</cron>
Peter