title: How to generate 8 bytes unique id from GUID?
body: <p>I try to use long as unique id within our C# application (not global, and only for one session) for our events. Do you know if the following will generate an unique long id?</p>
  
  <pre><code>public long GenerateId()
  {
   byte[] buffer = Guid.NewGuid().ToByteArray();
   return BitConverter.ToInt64(buffer, 0);
  }
  </code></pre>
  
  <p>Why we not use GUID directly? We think 8 bytes long is good enough.</p>