title: How to use enyim memcached client with amazon elasticache in c#
body: <p>I have created a cache cluster on Amazon ElastiCache. It has given me an endpoint address.
  Now I want to store the data in Amazon ElastiCache. For that I am making use of enyim memcached client.</p>
  
  <p>The server gives an error as;</p>
  
  <blockquote>
    <p>Type initializer for Enyim.Caching.Memcached.ServerPool threw an error</p>
  </blockquote>
  
  <p>My config looks like this;</p>
  
  <pre><code>&lt;enyim.com&gt;
      &lt;memcached&gt;
        &lt;servers&gt;
          &lt;!-- put your own server(s) here--&gt;
          &lt;add address="&lt;MyendPointAddress" port="11211" /&gt;
        &lt;/servers&gt;
        &lt;socketPool minPoolSize="10" maxPoolSize="100"
        connectionTimeout="00:01:10" deadTimeout="00:05:00" /&gt;
      &lt;/memcached&gt;
    &lt;/enyim.com&gt;
  </code></pre>
  
  <p>In C# I have written something like this;</p>
  
  <pre><code>using (MemcachedClient client = new MemcachedClient())
              {
                  client.Store(Enyim.Caching.Memcached.StoreMode.Add, key, value);
                  var l = client.Get(key);
              }
  </code></pre>
  
  <p>When I use local host, the code doesn't throw any error, but doesn't store anything.</p>
  
  <p>Edit: 
  Now I have shifted to BeIT memcached client. It runs fine, however returns null as output for Get() requests.</p>