Package de.dlr.proseo.model.dao
Interface JobRepository
- All Superinterfaces:
org.springframework.data.repository.CrudRepository<Job,,Long> org.springframework.data.jpa.repository.JpaRepository<Job,,Long> org.springframework.data.repository.ListCrudRepository<Job,,Long> org.springframework.data.repository.ListPagingAndSortingRepository<Job,,Long> org.springframework.data.repository.PagingAndSortingRepository<Job,,Long> org.springframework.data.repository.query.QueryByExampleExecutor<Job>,org.springframework.data.repository.Repository<Job,Long>
@Transactional
public interface JobRepository
extends org.springframework.data.jpa.repository.JpaRepository<Job,Long>
Data Access Object for the Job class
- Author:
- Dr. Thomas Bassler
-
Method Summary
Modifier and TypeMethodDescriptionintcountAllByJobStateAndProcessingOrder(Job.JobState jobState, long orderId) intcountJobFailedByProcessingOrderId(long id) intintcountJobOnHoldByProcessingOrderId(long id) findAllByJobState(Job.JobState jobState) findAllByJobStateAndProcessingOrder(Job.JobState jobState, long orderId) Deprecated.findAllByProcessingOrder(long orderId) Methods inherited from interface org.springframework.data.repository.CrudRepository
count, delete, deleteAll, deleteAll, deleteAllById, deleteById, existsById, findById, saveMethods inherited from interface org.springframework.data.jpa.repository.JpaRepository
deleteAllByIdInBatch, deleteAllInBatch, deleteAllInBatch, deleteInBatch, findAll, findAll, flush, getById, getOne, getReferenceById, saveAllAndFlush, saveAndFlushMethods inherited from interface org.springframework.data.repository.ListCrudRepository
findAll, findAllById, saveAllMethods inherited from interface org.springframework.data.repository.ListPagingAndSortingRepository
findAllMethods inherited from interface org.springframework.data.repository.PagingAndSortingRepository
findAllMethods inherited from interface org.springframework.data.repository.query.QueryByExampleExecutor
count, exists, findAll, findBy, findOne
-
Method Details
-
findAllByJobState
@Query("select j from Job j where j.jobState = ?1") List<Job> findAllByJobState(Job.JobState jobState) -
findAllByProcessingOrder
-
findAllByJobStateAndProcessingOrder
@Deprecated @Query("select j from Job j where j.jobState = ?1 and j.processingOrder.id = ?2") List<Job> findAllByJobStateAndProcessingOrder(Job.JobState jobState, long orderId) Deprecated. -
countAllByJobStateAndProcessingOrder
@Query("select count(*) from Job j where j.jobState = ?1 and j.processingOrder.id = ?2") int countAllByJobStateAndProcessingOrder(Job.JobState jobState, long orderId) -
countJobNotFinishedByProcessingOrderId
@Query("SELECT COUNT(*) FROM Job j WHERE j.processingOrder.id = ?1 AND j.jobState NOT IN (\'CLOSED\', \'COMPLETED\', \'FAILED\')") int countJobNotFinishedByProcessingOrderId(long id) -
countJobFailedByProcessingOrderId
@Query("SELECT COUNT(*) FROM Job j WHERE j.processingOrder.id = ?1 AND j.jobState = \'FAILED\'") int countJobFailedByProcessingOrderId(long id) -
countJobOnHoldByProcessingOrderId
@Query("SELECT COUNT(*) FROM Job j WHERE j.processingOrder.id = ?1 AND j.jobState = \'ON_HOLD\'") int countJobOnHoldByProcessingOrderId(long id)
-