skip to Main Content

I’ve almost completed migrating based on google’s instructions.

It’s very nice to not have to call into the app-engine libraries whatsoever.

However, now I must replace my calls to app-engine-standard memcached.

Here’s what the guide says: “To use a memcache service on App Engine, use Redis Labs Memcached Cloud instead of App Engine Memcache.”

So is this my only option; a third party? They don’t even list pricing on their page if GCE is selected.

I also see in the standard environment how-to guides there is a guide on Connecting to internal resources in a VPC network.

From that link it mentions Cloud Memorystore. I can’t find any examples if this is advisable or possible to do on GAE standard. Of course it wasn’t previously possible but now that GAE standard has become much more “standard”, I think it should be possible?

Thanks for any advice on the best way forward.

3

Answers


  1. I’ve been thinking about this. 2nd gen instances have twice the ram, so if global cache isn’t required (as in items don’t change once created – (name items using their sha256)), you can run your own local threadsafe memcache (such as https://github.com/dgraph-io/ristretto) and allocate some of the extra ram to it. It’ll be faster than Memcache was, so requests can be serviced even faster, keeping the number of instances low.
    You could make it global for data that does change, by using pub/sub between instances, but I think that’s significantly more work.

    Login or Signup to reply.
  2. Memorystore appears to be Google’s replacement:
    https://cloud.google.com/memorystore/

    You connect to it using this guide:
    https://cloud.google.com/appengine/docs/standard/go/using-memorystore

    Alas it costs about $1.20/GB per day with no free quota.

    Thus, if your data doesn’t change, and requires less than 100MB of cache at a time, the first answer might be better (free). Also, your data won’t explode the instance as you can control the max size of the cache.

    However, if your data changes or you need more cache, MemoryStore is a more direct replacement to MemCache – just costs money.

    Login or Signup to reply.
  3. To ease the migration to 1.12, I have been thinking of using this solution:

    1. create a dedicated app using the 1.11 runtime.
    2. setup twirp endpoints to act as a proxy for all the deprecated app engine services (memcache, mail, search…)
    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search