<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 async def _on_heartbeat(self, update):
 """Receive a new heartbeat for a service."""


        name = update['service']

        if name not in self.services:
            return

        with self._state_lock:
            self.services[name].heartbeat()