Naive retry logic, todo: fail after x retries