def METHOD_NAME(self, result):
    code = result[0]
    if code == 1:
        self.agentpool = result[1]
        self.agent_pool_ready()
        self.restart_ping()
    elif code == 2:
        self.remote_service(*result[1:])