Create a new job based on a jobConfig string

@param {string} jobName
@param {string} jobConfig
@param {object|undefined} customParams is optional
@param {function} callback
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);
      });
    }
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;
  }
419007
function (jobName, param, customParams, callback) {
      [jobName, param, customParams, callback] = doArgs(arguments, ['string', ['string', 'id,timestamp,result,duration'], ['object', {}], 'function']);

      // TODO better name and handle the "param" ???
      doRequest({
        urlPattern: [ALL_BUILDS, jobName, param],
        bodyProp: 'allBuilds'
      }, customParams, callback);
    }
974036
public static void init(String jobId) {
        JobContext parent = current_.get();
        JobContext ctx = new JobContext(parent);
        current_.set(ctx);
        // don't call setJobId(String)
        // as it will trigger listeners -- TODO fix me
        ctx.jobId = jobId;
        if (null == parent) {
            Act.eventBus().trigger(new JobContextInitialized(ctx));
        }
    }
717718
def _create_job(self, mapping):
        """"""
        job_id = self.bulk.create_insert_job(mapping["sf_object"], contentType="CSV")
        self.logger.info("  Created bulk job {}".format(job_id))

        # Upload batches
        local_ids_for_batch = {}
        for batch_file, local_ids in self._get_batches(mapping):
            batch_id = self.bulk.post_batch(job_id, batch_file)
            local_ids_for_batch[batch_id] = local_ids
            self.logger.info("    Uploaded batch {}".format(batch_id))

        self.bulk.close_job(job_id)
        return job_id, local_ids_for_batch
422562
function (customParams, callback) {
      [customParams, callback] = doArgs(arguments, [['object', {}], 'function']);

      customParams.depth = 1;

      doRequest({
        urlPattern: [PLUGINS],
        failureStatusCodes: [HTTP_CODE_302],
        noparse: true,
        bodyProp: 'plugins'
      }, customParams, callback);
    }
118823
function job_info(jobName, customParams, callback) {
      var _doArgs31 = doArgs(arguments, ['string', ['object', {}], 'function']);

      var _doArgs32 = _slicedToArray(_doArgs31, 3);

      jobName = _doArgs32[0];
      customParams = _doArgs32[1];
      callback = _doArgs32[2];


      doRequest({
        urlPattern: [JOB_INFO, jobName]
      }, customParams, callback);
    }
1244897
function (jobName, buildNumber, customParams, callback) {
      [jobName, buildNumber, customParams, callback] = doArgs(arguments, ['string', 'string|number', ['object', {}], 'function']);

      doRequest({
        urlPattern: [JOB_OUTPUT, jobName, buildNumber],
        noparse: true
      }, customParams, callback);
    }
473629
def _create_job(self, func, args=None, kwargs=None, commit=True,
                    result_ttl=None, ttl=None, id=None, description=None,
                    queue_name=None, timeout=None, meta=None):
        
        if args is None:
            args = ()
        if kwargs is None:
            kwargs = {}
        job = self.job_class.create(
                func, args=args, connection=self.connection,
                kwargs=kwargs, result_ttl=result_ttl, ttl=ttl, id=id,
                description=description, timeout=timeout, meta=meta)
        if self._queue is not None:
            job.origin = self._queue.name
        else:
            job.origin = queue_name or self.queue_name
        if commit:
            job.save()
        return job
531026
public function registerJob(string $jobName, callable $callback) : bool
    {
        $this->callbacks[$jobName] = $callback;
        $this->jobSocket->subscribe($jobName);

        // register job at server:
        $this->replySocket->send(json_encode([
            'request' => 'register_job',
            'worker_id' => $this->workerId,
            'job_name' => $jobName
        ]));
        $response = $this->replySocket->recv();
        return ($response === 'ok');
    }
785465
function last_success(jobName, customParams, callback) {
      var _doArgs43 = doArgs(arguments, ['string', ['object', {}], 'function']);

      var _doArgs44 = _slicedToArray(_doArgs43, 3);

      jobName = _doArgs44[0];
      customParams = _doArgs44[1];
      callback = _doArgs44[2];


      doRequest({
        method: 'POST',
        urlPattern: [LAST_SUCCESS, jobName]
      }, customParams, callback);
    }
51884
@Override
  JobDesc create(QualifiedJobId qualifiedJobId, long submitTimeMillis,
      Configuration jobConf) {
    // TODO: Get the actual values appropriate for the plain Hadoop jobs.

    String appId = getAppId(jobConf);

    long appSubmitTimeMillis = jobConf.getLong(Constants.MR_RUN_CONF_KEY,
        submitTimeMillis);


    return create(qualifiedJobId, jobConf, appId, Constants.UNKNOWN,
        Framework.NONE, appSubmitTimeMillis);
  }
1229548
function (jobName, modifyFunction, customParams, callback) {
      [jobName, modifyFunction, customParams, callback] = doArgs(arguments, ['string', 'function', ['object', {}], 'function']);

      const self = this;

      self.get_config_xml(jobName, customParams, function (error, data) {
        if (error) {
          callback(error, data);
          return;
        }

        // Modify the config data
        data = modifyFunction(data);

        self.update_job(jobName, data, customParams, callback);
      });
    }
1343031
function all_jobs_in_view(viewId, customParams, callback) {
      var _doArgs69 = doArgs(arguments, ['string', ['object', {}], 'function']);

      var _doArgs70 = _slicedToArray(_doArgs69, 3);

      viewId = _doArgs70[0];
      customParams = _doArgs70[1];
      callback = _doArgs70[2];


      doRequest({
        urlPattern: [VIEW_INFO, viewId],
        bodyProp: 'jobs'
      }, customParams, callback);
    }
1128244
function copy_job(jobName, newJobName, modifyFunction, customParams, callback) {
      var _doArgs35 = doArgs(arguments, ['string', 'string', 'function', ['object', {}], 'function']);

      var _doArgs36 = _slicedToArray(_doArgs35, 5);

      jobName = _doArgs36[0];
      newJobName = _doArgs36[1];
      modifyFunction = _doArgs36[2];
      customParams = _doArgs36[3];
      callback = _doArgs36[4];


      var self = this;

      this.get_config_xml(jobName, customParams, function (error, data) {
        if (error) {
          callback(error, data);
          return;
        }

        // Modify the data
        data = modifyFunction(data);

        self.create_job(newJobName, data, customParams, callback);
      });
    }
773828
def new_job(self, task, inputdata, launcher_name="Unknown", debug=False):
        
        bjobid = uuid.uuid4()
        self._waiting_jobs.append(str(bjobid))
        self._client.new_job(task, inputdata,
                             (lambda result, grade, problems, tests, custom, archive, stdout, stderr:
                              self._callback(bjobid, result, grade, problems, tests, custom, archive, stdout, stderr)),
                             launcher_name, debug)
        return bjobid
990658
function (jobName, customParams, callback) {
      [jobName, customParams, callback] = doArgs(arguments, ['string', ['object', {}], 'function']);

      doRequest({
        urlPattern: [LAST_BUILD, jobName]
      }, customParams, callback);
    }