Added 'ping' method to Computation to check heartbeat.

'ping' method in Computation can be used to check if the server
is reachable. See 'discoro_client.py' on how it can be used.

In '_discoro_process', call 'terminate' to wait and shutdown the
scheduler (earlier version used 'join' which doesn't send
'peer_closed' method that waits for all queued messages to be
delivered).

Misc cleanups elsewhere.