title: How do you implement AWS Elasticache auto discovery for node.js
body: <p>I'm a node noob and trying to understand how one would implement <a href="http://docs.aws.amazon.com/AmazonElastiCache/latest/UserGuide/AutoDiscovery.html">auto discovery</a> in a node.js application.  I'm going to use the <a href="http://nodejs.org/api/cluster.html#cluster_cluster">cluster module</a> and want each worker process to be kept up to date (and persistently connected to) the elasticache nodes.</p>
  
  <p>Since there is no concept of shared memory (like PHP APC) would you have to have code that runs in each worker, that wakes up every X seconds and somehow updates the list of IP's and re-connects the memcache client?</p>
  
  <p>How do people solve this today? Example code would be much appreciated.</p>