Is going to have support to appengine memcache soon?
For memcache, you should just use the memcache client library for Node JS. I think the bigger question is ... where do you point your memcache client ...? And I don't know the answer to that just yet.
@ajessup Do you know where I'd point my Memcache client inside App Engine + Node ? Should I spin up my own machine running Memcache?
The team is looking at adding native memcached support within the Managed VM, rather require than a proprietary API. Once that's available should be able to use a native node client library that can speak the memcached wire protocol (eg. https://www.npmjs.com/package/memcached) and point it to a particular port on localhost.
When it's available we'll update the documentation at https://cloud.google.com/appengine/docs/managed-vms/custom-runtimes with information like the port number you'll need to access it.
In the meantime, spinning up a memcache cluster on GCE in the same zone as your Managed VM application seems like a great suggestion.
Cool -- going to close this out then. Thanks @ajessup
Just finding this thread now.
@jgeewax Could you point me in the direction on how to setup the memcached library with GCE and my Managed VM?
Thank you!
I think what @ajessup is saying would be to note where your VMs are in App Engine, and then turn on a GCE instance in that same cluster.
Then you just point your memcache client at the GCE VM (make sure to open the ports for MC, should be 11211) so that you Managed VMs can talk to your Memcache VM.
Does that make sense?
If you're still having trouble, could you take this conversation over to StackOverflow ? Don't want this to get lost here in an GH issue :)
@sebelga Actually you can use App Engine's memcache service (which is available to every App Engine module, including those running Managed VMs). For Node.js, you can use any nodejs client library that supports the memcached wire protocol (which is why we haven't provided one in the gcloud library).
You can read a more complete guide on working with Memcache here https://cloud.google.com/appengine/docs/managed-vms/nodejs/caching-application-data
Great, thank you @jgeewax and @ajessup for the info. I will have a look at the App Engine's memcache service.
Does this work from Cloud Functions?
For those who might be interested, I created a small library for caching entities.
https://github.com/sebelga/gstore-cache
It works with Redis and so should work from Cloud Functions
Is there anything at all to use the App Engine memcache service?
I tried using https://github.com/googlearchive/appengine-nodejs but I am getting a connection timeout:
Error: connect ETIMEDOUT 74.125.202.95:10001
If the service is available I could use any nodejs memcache library but I don't know where to point it to. Is the service available at all?
Most helpful comment
Does this work from Cloud Functions?