@Validated public class JobResolverServiceImpl extends java.lang.Object implements JobResolverService
JobResolverService APIs.| Constructor and Description |
|---|
JobResolverServiceImpl(DataServices dataServices,
@NotEmpty java.util.List<ClusterSelector> clusterSelectors,
CommandSelector commandSelector,
io.micrometer.core.instrument.MeterRegistry registry,
JobsProperties jobsProperties,
org.springframework.core.env.Environment environment)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
ResolvedJob |
resolveJob(java.lang.String id)
Given the id of a job that was successfully submitted to the system this API will attempt to resolve all the
concrete details (cluster, command, resources, etc) needed for the system to actually launch the job.
|
ResolvedJob |
resolveJob(java.lang.String id,
@Valid com.netflix.genie.common.external.dtos.v4.JobRequest jobRequest,
boolean apiJob)
Given a job request resolve all the details needed to run a job.
|
public JobResolverServiceImpl(DataServices dataServices, @NotEmpty @NotEmpty java.util.List<ClusterSelector> clusterSelectors, CommandSelector commandSelector, io.micrometer.core.instrument.MeterRegistry registry, JobsProperties jobsProperties, org.springframework.core.env.Environment environment)
dataServices - The DataServices encapsulation instance to useclusterSelectors - The ClusterSelector implementations to usecommandSelector - The CommandSelector implementation to useregistry - The MeterRegistrymetrics repository to usejobsProperties - The properties for running a job set by the userenvironment - The Spring application Environment for dynamic property resolution@Nonnull @Transactional public ResolvedJob resolveJob(java.lang.String id) throws com.netflix.genie.common.internal.exceptions.checked.GenieJobResolutionException, com.netflix.genie.common.internal.exceptions.unchecked.GenieJobResolutionRuntimeException
JobStatus.RESOLVED.resolveJob in interface JobResolverServiceid - The id of the job to resolve. The job must exist and its status must return true from
JobStatus.isResolvable()ResolvedJob instance containing all the concrete information needed to execute the jobcom.netflix.genie.common.internal.exceptions.checked.GenieJobResolutionException - When the job cannot resolved due to unsatisfiable constraintscom.netflix.genie.common.internal.exceptions.unchecked.GenieJobResolutionRuntimeException - When the job fails to resolve due to a runtime error.@Nonnull public ResolvedJob resolveJob(java.lang.String id, @Valid @Valid com.netflix.genie.common.external.dtos.v4.JobRequest jobRequest, boolean apiJob) throws com.netflix.genie.common.internal.exceptions.checked.GenieJobResolutionException, com.netflix.genie.common.internal.exceptions.unchecked.GenieJobResolutionRuntimeException
resolveJob in interface JobResolverServiceid - The id of the jobjobRequest - The job request containing all details a user wants to have for their jobapiJob - true if this job was submitted via the REST API. false otherwise.ResolvedJob instancecom.netflix.genie.common.internal.exceptions.checked.GenieJobResolutionException - When the job cannot resolved due to unsatisfiable constraintscom.netflix.genie.common.internal.exceptions.unchecked.GenieJobResolutionRuntimeException - When the job fails to resolve due to a runtime error.