diff --git a/ruoyi-quartz/src/main/java/com/ruoyi/quartz/service/impl/SysJobServiceImpl.java b/ruoyi-quartz/src/main/java/com/ruoyi/quartz/service/impl/SysJobServiceImpl.java index d7bc6c984..57b571c5e 100644 --- a/ruoyi-quartz/src/main/java/com/ruoyi/quartz/service/impl/SysJobServiceImpl.java +++ b/ruoyi-quartz/src/main/java/com/ruoyi/quartz/service/impl/SysJobServiceImpl.java @@ -75,7 +75,7 @@ public class SysJobServiceImpl implements ISysJobService * @param job 调度信息 */ @Override - @Transactional + @Transactional(rollbackFor = Exception.class) public int pauseJob(SysJob job) throws SchedulerException { Long jobId = job.getJobId(); @@ -95,7 +95,7 @@ public class SysJobServiceImpl implements ISysJobService * @param job 调度信息 */ @Override - @Transactional + @Transactional(rollbackFor = Exception.class) public int resumeJob(SysJob job) throws SchedulerException { Long jobId = job.getJobId(); @@ -115,7 +115,7 @@ public class SysJobServiceImpl implements ISysJobService * @param job 调度信息 */ @Override - @Transactional + @Transactional(rollbackFor = Exception.class) public int deleteJob(SysJob job) throws SchedulerException { Long jobId = job.getJobId(); @@ -135,7 +135,7 @@ public class SysJobServiceImpl implements ISysJobService * @return 结果 */ @Override - @Transactional + @Transactional(rollbackFor = Exception.class) public void deleteJobByIds(Long[] jobIds) throws SchedulerException { for (Long jobId : jobIds) @@ -151,7 +151,7 @@ public class SysJobServiceImpl implements ISysJobService * @param job 调度信息 */ @Override - @Transactional + @Transactional(rollbackFor = Exception.class) public int changeStatus(SysJob job) throws SchedulerException { int rows = 0; @@ -173,7 +173,7 @@ public class SysJobServiceImpl implements ISysJobService * @param job 调度信息 */ @Override - @Transactional + @Transactional(rollbackFor = Exception.class) public void run(SysJob job) throws SchedulerException { Long jobId = job.getJobId(); @@ -191,7 +191,7 @@ public class SysJobServiceImpl implements ISysJobService * @param job 调度信息 调度信息 */ @Override - @Transactional + @Transactional(rollbackFor = Exception.class) public int insertJob(SysJob job) throws SchedulerException, TaskException { job.setStatus(ScheduleConstants.Status.PAUSE.getValue()); @@ -209,7 +209,7 @@ public class SysJobServiceImpl implements ISysJobService * @param job 调度信息 */ @Override - @Transactional + @Transactional(rollbackFor = Exception.class) public int updateJob(SysJob job) throws SchedulerException, TaskException { SysJob properties = selectJobById(job.getJobId());