implementation of heartbeat proto