title: Locking on string-key
body: <p>How do I perform a <code>lock</code> based on a specific string-key?</p>
  
  <pre><code>public void PerformUpdate(string key)
  {
      // TODO: Refine this, since they key-string won't 
      // be the same instance between calls
  
      lock(key)
      {
          PerformUpdateImpl()
      }
  }
  </code></pre>
  
  <p>I've tried to keep lock-objects in a <code>ConcurrentDictionary</code>, but somehow this doesn't hold up either.</p>