use of com.thinkbiganalytics.metadata.api.jobrepo.job.BatchJobInstance in project kylo by Teradata.
the class JpaBatchJobExecutionProvider method createNewJobExecution.
/**
* Crate a new job exection from a provenance event
*
* @param event the provenance event indicating it is the start of a job
* @return the job execution
*/
private JpaBatchJobExecution createNewJobExecution(ProvenanceEventRecordDTO event, OpsManagerFeed feed) {
BatchJobInstance jobInstance = createJobInstance(event);
JpaBatchJobExecution jobExecution = createJobExecution(jobInstance, event, feed);
return jobExecution;
}
use of com.thinkbiganalytics.metadata.api.jobrepo.job.BatchJobInstance in project kylo by Teradata.
the class JpaBatchJobExecutionProvider method createJobInstance.
@Override
public BatchJobInstance createJobInstance(ProvenanceEventRecordDTO event) {
JpaBatchJobInstance jobInstance = new JpaBatchJobInstance();
jobInstance.setJobKey(jobKeyGenerator(event));
jobInstance.setJobName(event.getFeedName());
// wire this instance to the Feed
OpsManagerFeed feed = opsManagerFeedRepository.findByName(event.getFeedName());
jobInstance.setFeed(feed);
BatchJobInstance batchJobInstance = this.jobInstanceRepository.save(jobInstance);
return batchJobInstance;
}
Aggregations