code: @Override
    public void updateDeployment(final String host, final Deployment deployment, final String token)
        throws HostNotFoundException, JobNotDeployedException, TokenVerificationException {
      log.info("updating deployment {}: {}", deployment, host);
  
      final ZooKeeperClient client = provider.get("updateDeployment");
  
      final JobId jobId = deployment.getJobId();
      final Job job = getJob(client, jobId);
      final Deployment existingDeployment = getDeployment(host, jobId);
  
      if (job == null) {
        throw new JobNotDeployedException(host, jobId);
      }
      verifyToken(token, job);
  
      assertHostExists(client, host);
      assertTaskExists(client, host, deployment.getJobId());
  
      final String path = Paths.configHostJob(host, jobId);
      final Task task = new Task(job, deployment.getGoal(),
          existingDeployment.getDeployerUser(),
          existingDeployment.getDeployerMaster(),
          existingDeployment.getDeploymentGroupName());
      try {
        client.setData(path, task.toJsonBytes());
      } catch (Exception e) {
        throw new HeliosRuntimeException("updating deployment " + deployment
                                         + " on host " + host + " failed", e);
      }
    }
docs: Used to update the existing deployment of a job.