Gibt den passenden SEPA Generator für die angegebene PAIN-Version.

@param job     der zu erzeugende Job.
@param version die PAIN-Version.
@return ISEPAGenerator
@throws IllegalAccessException
@throws InstantiationException
@throws ClassNotFoundException
180352
public static PainGeneratorIf get(AbstractHBCIJob job, SepaVersion version) throws ClassNotFoundException,
        InstantiationException, IllegalAccessException {
        String jobname = ((AbstractSEPAGV) job).getPainJobName(); // referenzierter pain-Geschäftsvorfall
        return get(jobname, version);
    }
436460
@Override
	public JobExecutionResult execute(String jobName) throws Exception {
		if (executor == null) {
			startNewSession();
		}

		Plan p = createProgramPlan(jobName);

		// Session management is disabled, revert this commit to enable
		//p.setJobId(jobID);
		//p.setSessionTimeout(sessionTimeout);

		JobExecutionResult result = executor.executePlan(p);

		this.lastJobExecutionResult = result;
		return result;
	}
906482
@Override
	public JobExecutionResult executePlan(Plan plan) throws Exception {
		if (plan == null) {
			throw new IllegalArgumentException("The plan may not be null.");
		}

		JobWithJars p = new JobWithJars(plan, this.jarFiles, this.globalClasspaths);
		return executePlanWithJars(p);
	}
1262176
@Override
  @Nullable
  public Object startJob()
  {
    final Object metadata = appenderator.startJob();
    if (metadata != null) {
      throw new ISE("Metadata should be null because BatchAppenderatorDriver never persists it");
    }
    return null;
  }
384389
public static final ApiVersionNotFoundException apiVersionNotFoundException(String apiId, String version) {
        return new ApiVersionNotFoundException(Messages.i18n.format("ApiVersionDoesNotExist", apiId, version)); //$NON-NLS-1$
    }
935973
public Set<String> configureJob(Job job) throws FileNotFoundException, IOException, TupleMRException {
		Set<String> instanceFiles = new HashSet<String>();
		for(Output output : getNamedOutputs()) {
			try {
				if(output.isDefault) {
					instanceFiles.add(PangoolMultipleOutputs.setDefaultNamedOutput(job, output.outputFormat,
					    output.keyClass, output.valueClass));
				} else {
					instanceFiles.add(PangoolMultipleOutputs.addNamedOutput(job, output.name, output.outputFormat,
					    output.keyClass, output.valueClass));
				}
			} catch(URISyntaxException e1) {
				throw new TupleMRException(e1);
			}
			for(Map.Entry<String, String> contextKeyValue : output.specificContext.entrySet()) {
				PangoolMultipleOutputs.addNamedOutputContext(job, output.name, contextKeyValue.getKey(),
				    contextKeyValue.getValue());
			}
		}
		return instanceFiles;
	}
392032
public UUID submitJob(ParallelizableJob job) throws Exception {
    return submitJob(job, job.getClass().getSimpleName());
  }
1293859
@Bean
  public JobFactory<FileIngestJobExecution> fileIngestJobFactory() {
    return new JobFactory<FileIngestJobExecution>() {
      @Override
      public Job createJob(FileIngestJobExecution fileIngestJobExecution) {
        final String targetEntityId = fileIngestJobExecution.getTargetEntityId();
        final String url = fileIngestJobExecution.getUrl();
        final String loader = fileIngestJobExecution.getLoader();
        String dataExplorerURL = menuReaderService.findMenuItemPath("dataexplorer");
        fileIngestJobExecution.setResultUrl(
            format("{0}?entity={1}", dataExplorerURL, targetEntityId));
        return progress ->
            fileIngester.ingest(
                targetEntityId, url, loader, fileIngestJobExecution.getIdentifier(), progress);
      }
    };
  }
1068759
public ISession getSession(String id, int version, boolean isSessionAccess) {
        //create local variable - JIT performance improvement
        final boolean isTraceOn = com.ibm.websphere.ras.TraceComponent.isAnyTracingEnabled();
        if (isTraceOn && LoggingUtil.SESSION_LOGGER_WAS.isLoggable(Level.FINE)) {
            LoggingUtil.SESSION_LOGGER_WAS.entering(methodClassName, methodNames[GET_SESSION], "id = " + id);
            LoggingUtil.SESSION_LOGGER_WAS.logp(Level.FINE, methodClassName, methodNames[GET_SESSION], "Store = " + this);
        }
        if (inProcessOfStopping) {
            throwException("SessionContext.accessWhenStop");
        }
        BackedSession session = ((BackedHashMap) _sessions).getSession(id, version, isSessionAccess);//why not call this -> ((BackedHashMap)_sessions).getSession(id, version);
        if (isTraceOn && LoggingUtil.SESSION_LOGGER_WAS.isLoggable(Level.FINER)) {
            LoggingUtil.SESSION_LOGGER_WAS.exiting(methodClassName, methodNames[GET_SESSION], "session = " + session);
        }
        return session;
    }
101123
private void findSpecNameForGV(String jobnameLL) {
        int maxVersion = 0;
        StringBuilder key = new StringBuilder();

        // alle param-segmente durchlaufen
        Map<String, String> bpd = passport.getBPD();
        for (String path : bpd.keySet()) {
            key.setLength(0);
            key.append(path);

            if (key.indexOf("Params") == 0) {
                key.delete(0, key.indexOf(".") + 1);

                // wenn segment mit namen des aktuellen jobs gefunden wurde
                if (key.indexOf(jobnameLL + "Par") == 0 &&
                    key.toString().endsWith(".SegHead.code")) {
                    key.delete(0, jobnameLL.length() + ("Par").length());

                    // extrahieren der versionsnummer aus dem spez-namen
                    String st = key.substring(0, key.indexOf("."));
                    int version = 0;

                    try {
                        version = Integer.parseInt(st);
                    } catch (Exception e) {
                        log.warn("found invalid job version: key=" + key + ", jobnameLL=" + jobnameLL + " (this is a " +
                            "known, but harmless bug)");
                    }

                    // merken der größten jemals aufgetretenen versionsnummer
                    if (version != 0) {
                        log.debug("task " + jobnameLL + " is supported with segment version " + st);
                        if (version > maxVersion) {
                            maxVersion = version;
                        }
                    }
                }
            }
        }

        if (maxVersion == 0 && !jobnameLL.equals(GVRawSEPA.getLowlevelName())) {
            maxVersion = 1;
            log.warn("Using segment version " + maxVersion + " for job " + jobnameLL + ", although not found in BPD. " +
                "This may fail");
            throw new JobNotSupportedException(jobnameLL);
        }

        // namen+versionsnummer speichern
        this.jobName = jobnameLL;
        this.segVersion = maxVersion;
        this.name = jobnameLL + this.segVersion;
    }
1254426
public JobReport execute(Job job) {
        try {
            return executorService.submit(job).get();
        } catch (InterruptedException | ExecutionException e) {
            throw new RuntimeException("Unable to execute job " + job.getName(), e);
        }
    }
769473
public void setJavaSourceVersion(String version) {
		final JavaVersion javaVersion = JavaVersion.fromQualifier(version);
		if (javaVersion == null) {
			final List<String> qualifiers = new ArrayList<>();
			for (final JavaVersion vers : JavaVersion.values()) {
				qualifiers.addAll(vers.getAllQualifiers());
			}

			throw new RuntimeException(MessageFormat.format(
					Messages.SarlBatchCompiler_0, version, Joiner.on(Messages.SarlBatchCompiler_1).join(qualifiers)));
		}
		getGeneratorConfig().setJavaSourceVersion(javaVersion);
	}
573781
public
  RunningJob submitJobInternal(JobConf job
                               ) throws FileNotFoundException,
                                        ClassNotFoundException,
                                        InterruptedException,
                                        IOException {
    /*
     * configure the command line options correctly on the submitting dfs
     */
    boolean shared = job.getBoolean("mapred.cache.shared.enabled", false);

    JobID jobId = jobSubmitClient.getNewJobId();
    Path submitJobDir = new Path(getSystemDir(), jobId.toString());
    Path sharedFilesDir =
      new Path(getSystemDir(), jobSubmitClient.CAR);
    Path submitSplitFile = new Path(submitJobDir, "job.split");

    getFs();
    if (jobSubmitClient instanceof LocalJobRunner) {
      symLinkAndConfigureFiles(job);
    } else {
      copyAndConfigureFiles(job,
          (shared) ? sharedFilesDir : submitJobDir, shared);
    }

    Path submitJobFile = new Path(submitJobDir, "job.xml");
    int reduces = job.getNumReduceTasks();
    JobContext context = new JobContext(job, jobId);

    // Check the output specification
    if (reduces == 0 ? job.getUseNewMapper() : job.getUseNewReducer()) {
      org.apache.hadoop.mapreduce.OutputFormat<?,?> output =
        ReflectionUtils.newInstance(context.getOutputFormatClass(), job);
      output.checkOutputSpecs(context);
    } else {
      job.getOutputFormat().checkOutputSpecs(fs, job);
    }

    // Create the splits for the job
    LOG.debug("Creating splits at " + fs.makeQualified(submitSplitFile));
    List<RawSplit> maps;
    if (job.getUseNewMapper()) {
      maps = computeNewSplits(context);
    } else {
      maps = computeOldSplits(job);
    }
    job.setNumMapTasks(maps.size());

    if (!isJobTrackerInProc) {
      JobConf conf = null;
      if (job.getUseNewMapper()) {
        conf = context.getJobConf();
      } else {
        conf = job;
      }
      writeComputedSplits(conf, maps, submitSplitFile);
      job.set("mapred.job.split.file", submitSplitFile.toString());
    } else {
      synchronized(JobClient.jobSplitCache) {
        if (JobClient.jobSplitCache.containsKey(jobId)) {
          throw new IOException("Job split already cached " + jobId);
        }
        JobClient.jobSplitCache.put(jobId, maps);
      }
      synchronized(JobClient.jobConfCache) {
        if (JobClient.jobConfCache.containsKey(jobId)) {
          throw new IOException("Job conf already cached " + jobId);
        }
        jobConfCache.put(jobId, job);
      }
    }
    // Write job file to JobTracker's fs
    FSDataOutputStream out =
      FileSystem.create(fs, submitJobFile,
          new FsPermission(JOB_FILE_PERMISSION));
    try {
      job.writeXml(out);
    } finally {
      out.close();
    }

    //
    // Now, actually submit the job (using the submit name)
    //
    JobStatus status = jobSubmitClient.submitJob(jobId);
    if (status != null) {
      return new NetworkedJob(status);
    } else {
      throw new IOException("Could not launch job");
    }
  }
227409
String processVersion(String version) {
    if (version == null || version.trim().isEmpty() || version.equals(APPENGINE_CONFIG)) {
      throw new IllegalArgumentException(VERSION_ERROR);
    } else if (version.equals(GCLOUD_CONFIG)) {
      return null;
    }
    return version;
  }
311022
public static String normalisedVersion(String version, String sep,
			int maxWidth) {
		if (version == null) {
			return null;
		}
		String[] split = Pattern.compile(sep, Pattern.LITERAL).split(version);
		StringBuilder sb = new StringBuilder();
		for (String s : split) {
			sb.append(String.format("%" + maxWidth + 's', s));
		}
		return sb.toString();
	}
1340646
public static RunningJob runJob(JobConf job) throws IOException {
    JobClient jc = new JobClient(job);
    RunningJob rj = jc.submitJob(job);
    try {
      if (!jc.monitorAndPrintJob(job, rj)) {
        throw new IOException("Job failed!");
      }
    } catch (InterruptedException ie) {
      Thread.currentThread().interrupt();
    }
    return rj;
  }
629858
@Override
    public byte[] transform(ClassLoader loader,
                            String className,
                            Class<?> classBeingRedefined,
                            ProtectionDomain protectionDomain,
                            byte[] classfileBuffer) throws IllegalClassFormatException {
        byte[] transformedBytes = providerClassTransformer.transform(loader, className, classBeingRedefined, protectionDomain, classfileBuffer);

        try {
            // Capture bytecode to disk if capturing is enabled and if a transformation has occurred.
            // The transform() method contract states a return value of null indicates no transformation.
            // We check the returned byte array just in case the JPA Implementation violates that contract.
            if (captureEnabled && transformedBytes != null) {
                File saveFile = new File(captureRootDir, className.replace('.', '/') + ".class");
                File targetDir = saveFile.getParentFile();

                if (mkdirs(targetDir)) {
                    if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
                        Tr.debug(tc, "Capturing enhanced Entity Class bytecode to " + saveFile.getAbsolutePath());
                    }

                    writeCapturedEnhancedBytecode(saveFile, transformedBytes);
                } else {
                    // Couldn't create the target directory
                    if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
                        Tr.debug(tc, "Failed to create capture directory " + targetDir.getAbsolutePath());
                    }
                }
            }
        } catch (Throwable t) {
            if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
                Tr.debug(tc, "Caught unexpected Exception while capturing " + className + ".", t);
            }
        }

        return transformedBytes;
    }