xm
2024-06-14 722af26bc6fec32bb289b1df51a9016a4935610f
提交 | 用户 | 时间
722af2 1 package com.xxl.job.admin.dao;
X 2
3 import com.xxl.job.admin.core.model.XxlJobLog;
4 import org.apache.ibatis.annotations.Mapper;
5 import org.apache.ibatis.annotations.Param;
6
7 import java.util.Date;
8 import java.util.List;
9 import java.util.Map;
10
11 /**
12  * job log
13  *
14  * @author xuxueli 2016-1-12 18:03:06
15  */
16 @Mapper
17 public interface XxlJobLogDao {
18
19     // exist jobId not use jobGroup, not exist use jobGroup
20     public List<XxlJobLog> pageList(@Param("offset") int offset,
21                                     @Param("pagesize") int pagesize,
22                                     @Param("jobGroup") int jobGroup,
23                                     @Param("jobId") int jobId,
24                                     @Param("triggerTimeStart") Date triggerTimeStart,
25                                     @Param("triggerTimeEnd") Date triggerTimeEnd,
26                                     @Param("logStatus") int logStatus);
27
28     public int pageListCount(@Param("offset") int offset,
29                              @Param("pagesize") int pagesize,
30                              @Param("jobGroup") int jobGroup,
31                              @Param("jobId") int jobId,
32                              @Param("triggerTimeStart") Date triggerTimeStart,
33                              @Param("triggerTimeEnd") Date triggerTimeEnd,
34                              @Param("logStatus") int logStatus);
35
36     public XxlJobLog load(@Param("id") long id);
37
38     public long save(XxlJobLog xxlJobLog);
39
40     public int updateTriggerInfo(XxlJobLog xxlJobLog);
41
42     public int updateHandleInfo(XxlJobLog xxlJobLog);
43
44     public int delete(@Param("jobId") int jobId);
45
46     public Map<String, Object> findLogReport(@Param("from") Date from,
47                                              @Param("to") Date to);
48
49     public List<Long> findClearLogIds(@Param("jobGroup") int jobGroup,
50                                       @Param("jobId") int jobId,
51                                       @Param("clearBeforeTime") Date clearBeforeTime,
52                                       @Param("clearBeforeNum") int clearBeforeNum,
53                                       @Param("pagesize") int pagesize);
54
55     public int clearLog(@Param("logIds") List<Long> logIds);
56
57     public List<Long> findFailJobLogIds(@Param("pagesize") int pagesize);
58
59     public int updateAlarmStatus(@Param("logId") long logId,
60                                  @Param("oldAlarmStatus") int oldAlarmStatus,
61                                  @Param("newAlarmStatus") int newAlarmStatus);
62
63     public List<Long> findLostJobIds(@Param("losedTime") Date losedTime);
64
65 }