title: Check status of the server continuously
body: <p>I have C# based client-server architecture. The client will connect to server and exchange data.  </p>
  
  <p>I need to check the server status continuously and if the server goes down (removed from the network or shut down) the client needs to indicate that.  </p>
  
  <p>If I am using <code>Ping</code> utility in the client program, which will be the best method in terms of performance i.e, monitor via a separate thread or through a background class?</p>
  
  <pre><code>public static bool GetPingResponse(string IpAddress, int timeout = 3000)
  {
      var ping = new Ping();
      var reply = ping.Send(IpAddress, timeout); 
      if (reply.Status == IPStatus.Success)
      {
          return true;
      }
      else
      {
          return false;
      }
  }
  </code></pre>
  
  <p>Is there any other option better than Ping in terms of performance and consuming the resource?</p>