Sets the job description which forms part of the Elastic MapReduce
 job flow name.
166667
def set_job_desc(segments, max_files)
      if segments.count > 0
        crawl_name = segments[0].crawl.crawl_name if segments[0].crawl.present?
        file_desc = max_files.nil? ? 'all files' : "#{max_files} files per segment"
      end

      "Crawl: #{crawl_name} Segments: #{segments.count} Parsing: #{file_desc}"
    end
1288491
def configure_job():
  """"""
  # See documentation:
  # https://cloud.google.com/ml-engine/reference/rest/v1/projects.jobs#traininginput
  training_input = {
      "pythonModule": "tensor2tensor.bin.t2t_trainer",
      "args": flags_as_args(),
      "region": text_encoder.native_to_unicode(default_region()),
      "runtimeVersion": RUNTIME_VERSION,
      "pythonVersion": "3.5" if sys.version_info.major == 3 else "2.7",
      "jobDir": FLAGS.output_dir,
      "scaleTier": "CUSTOM",
      "masterType": FLAGS.cloud_mlengine_master_type or get_default_master_type(
          num_gpus=FLAGS.worker_gpu)
  }
  if FLAGS.use_tpu:
    training_input["masterType"] = (FLAGS.cloud_mlengine_master_type or
                                    "standard")
    training_input["workerType"] = "cloud_tpu"
    training_input["workerCount"] = 1
  if FLAGS.hparams_range:
    tf.logging.info("Configuring hyperparameter tuning.")
    training_input["hyperparameters"] = configure_autotune(
        FLAGS.hparams_range,
        FLAGS.autotune_objective,
        FLAGS.autotune_maximize,
        FLAGS.autotune_max_trials,
        FLAGS.autotune_parallel_trials,
    )

  timestamp = datetime.datetime.now().strftime("%Y%m%d_%H%M%S")
  job_spec = {
      "jobId": "%s_%s_t2t_%s" % (FLAGS.model, FLAGS.problem, timestamp),
      "labels": {
          "model": FLAGS.model,
          "problem": FLAGS.problem,
          "hparams": FLAGS.hparams_set
      },
      "trainingInput": training_input,
  }
  return job_spec
984208
@Override
  public void setupHadoopJobProperties() {
    if (getJobProps().containsKey(HADOOP_GLOBAL_OPTS)) {
      String hadoopGlobalOps = getJobProps().getString(HADOOP_GLOBAL_OPTS);
      if (getJobProps().containsKey(HADOOP_OPTS)) {
        String hadoopOps = getJobProps().getString(HADOOP_OPTS);
        getJobProps().put(HADOOP_OPTS, String.format("%s %s", hadoopOps, hadoopGlobalOps));
      } else {
        getJobProps().put(HADOOP_OPTS, hadoopGlobalOps);
      }
    }
  }
260277
public void setResourceNamesOnProcessDefinitions(ParsedDeployment parsedDeployment) {
    for (ProcessDefinitionEntity processDefinition : parsedDeployment.getAllProcessDefinitions()) {
      String resourceName = parsedDeployment.getResourceForProcessDefinition(processDefinition).getName();
      processDefinition.setResourceName(resourceName);
    }
  }
1355804
public void setJobs(java.util.Collection<Job> jobs) {
        if (jobs == null) {
            this.jobs = null;
            return;
        }

        this.jobs = new com.amazonaws.internal.SdkInternalList<Job>(jobs);
    }
934288
public void setJobFlowStates(java.util.Collection<String> jobFlowStates) {
        if (jobFlowStates == null) {
            this.jobFlowStates = null;
            return;
        }

        this.jobFlowStates = new com.amazonaws.internal.SdkInternalList<String>(jobFlowStates);
    }
683549
def job_describe(object_id, input_params={}, always_retry=True, **kwargs):
    
    return DXHTTPRequest('/%s/describe' % object_id, input_params, always_retry=always_retry, **kwargs)
790042
def set_job(self, key, func, args):
        
        res, pk = key
        jobs, lock = self._jobs
        task = _tasks.UpdateTask(func(*args), key)
        with lock:
            job = jobs[res].get(pk)
            had = bool(job)
            if not job:
                job = task
                jobs[res][pk] = job
            else:
                task.cancel()
        self._log.debug('Scheduling: %s-%s (%s)', res.tag, pk,
                        'new task' if not had else 'dup')
        return job
291602
def setDescription(self, desc='No description'):
        """"""
        try:
            self._put_named_file('description', desc)
        except Exception, e:
            raise RepoError(e)
542172
function (jobName, jobConfig, customParams, callback) {
      [jobName, jobConfig, customParams, callback] = doArgs(arguments, ['string', 'string', ['object', {}], 'function']);

      // Set the created job name!
      customParams.name = jobName;

      const self = this;

      doRequest({
        method: 'POST',
        urlPattern: [JOB_CREATE],
        request: {
          body: jobConfig,
          headers: { 'Content-Type': 'application/xml' }
        },
        noparse: true
      }, customParams, function (error, data) {
        if (error) {
          callback(error, data);
          return;
        }
        self.job_info(jobName, customParams, callback);
      });
    }
181968
public void setTransformJobSummaries(java.util.Collection<TransformJobSummary> transformJobSummaries) {
        if (transformJobSummaries == null) {
            this.transformJobSummaries = null;
            return;
        }

        this.transformJobSummaries = new java.util.ArrayList<TransformJobSummary>(transformJobSummaries);
    }
1123480
@Override
    public void setJobQueue(int jobId, Queue queue)
    {
        JqmClientFactory.getClient().setJobQueue(jobId, queue);
    }
523184
@Override
	public Response setDescription( String applicationName, String desc ) {

		this.logger.fine( "Request: change the description of " + applicationName + "." );
		Response response = Response.ok().build();
		String lang = lang( this.manager );
		try {
			ManagedApplication ma = this.manager.applicationMngr().findManagedApplicationByName( applicationName );
			if( ma == null ) {
				response = handleError(
						Status.NOT_FOUND,
						new RestError( REST_INEXISTING, application( applicationName )),
						lang ).build();

			} else {
				this.manager.applicationMngr().updateApplication( ma, desc );
			}

		} catch( IOException e ) {
			response = RestServicesUtils.handleError(
					Status.FORBIDDEN,
					new RestError( ErrorCode.REST_UNDETAILED_ERROR, e ),
					lang ).build();
		}

		return response;
	}
131514
public void setJobStatesToNotify(java.util.Collection<String> jobStatesToNotify) {
        if (jobStatesToNotify == null) {
            this.jobStatesToNotify = null;
            return;
        }

        this.jobStatesToNotify = new java.util.ArrayList<String>(jobStatesToNotify);
    }
1297670
public void setName (final String name)
  {
    if (name == null || name.trim ().length () == 0)
    {
      throw new IllegalArgumentException ("Job name cannot be empty.");
    }

    m_sName = name;
    m_aKey = null;
  }
1152658
public void setJobName (final String jobName)
  {
    if (jobName == null || jobName.trim ().length () == 0)
    {
      throw new IllegalArgumentException ("Job name cannot be null or empty.");
    }

    m_sJobName = jobName;
  }
1256685
def job_details(job_id, connection=None):
    """"""
    if connection is None:
        connection = r
    data = connection.hgetall(job_key(job_id))

    job_data = {'id': job_id, 'schedule_at': int(connection.zscore(REDIS_KEY,
                                                                   job_id))}
    for key, value in data.items():
        try:
            decoded = value.decode('utf-8')
        except UnicodeDecodeError:
            decoded = value
        if decoded.isdigit():
            decoded = int(decoded)
        job_data[key.decode('utf-8')] = decoded
    return job_data