title: Porting socket server from Node.js to C#
body: <p>I've built multiple socket server apps in Node.js for a multi-user artificial intelligence app. We're looking at 1K to 10K active socket connections per box. However even when idle and with 0 active connections, some of my servers consume 50-100 MB of memory when running on Unix. I'm sure with a sensible platform like C# or C++, this should be close to 0 MB. So we are considering a port to a "better" platform. Now let my clarify my use case:</p>
  
  <ul>
  <li>This is not a "web server". No files are served.</li>
  <li>We do lots of CPU intensive data processing and certain portions have already been ported to C++ and pulled into node via native modules.</li>
  <li>We don't need to access much I/O (in most cases a few files are accessed, in some cases none, we don't use an RDBMS either)</li>
  </ul>
  
  <p>We went with node because it was Unix friendly (unlike .NET) and seemed easy to use. But with its current memory consumption we need to evaluate other options. Many have compared <a href="https://gist.github.com/ilyaigpetrov/f6df3e6f825ae1b5c7e2">Node.js with ASP.NET</a> but I need to build a socket server in C# or C++. </p>
  
  <p>I have significant experience with .NET and C++. There are libs like <a href="http://www.supersocket.net/">SuperSocket</a> (used by Redgate and Telerik) that handle all of the low-level stuff in .NET. I will have to find a similar socket framework for C++.</p>
  
  <p>So putting this all together, what are the advantages of using .NET or C++ over Node.js? And considering my servers are highly CPU-bound (not I/O bound) would the benefits of using .NET/C++ be significant or should I stick with Node.js? Any other comments regarding porting a Node.js app to C# or C++?</p>
  
  <p><strong>Bounty:</strong> I need advice and a recommended socket server library/implementation/example app in C# and/or C++. Must be open source. I need it to be high-performance, async and bug-free. Must support binary data transfer. Must run on Windows. Unix is a bonus.</p>