|
@@ -39,12 +39,20 @@ public class CheckTaskSchedule {
|
|
public void taskBiz() throws Exception {
|
|
public void taskBiz() throws Exception {
|
|
LoggerUtil.info(DateUtil.getTime());
|
|
LoggerUtil.info(DateUtil.getTime());
|
|
try {
|
|
try {
|
|
- if (DateUtil.getHour().equals("10") || DateUtil.getHour().equals("20")) {
|
|
|
|
|
|
+ // 8点重新生成下昨天数据
|
|
|
|
+ if (DateUtil.getHour().equals("08")) {
|
|
|
|
+ String lastDay = DateUtil.getAfterDay(-1);
|
|
|
|
+ LoggerUtil.info(lastDay + "执行开始:" + DateUtil.getTime());
|
|
|
|
+ executeBiz(lastDay);
|
|
|
|
+ LoggerUtil.info(lastDay + "执行结束:" + DateUtil.getTime());
|
|
|
|
+ }
|
|
|
|
+ // 10点、22点生成今天数据
|
|
|
|
+ if (DateUtil.getHour().equals("10") || DateUtil.getHour().equals("22")) {
|
|
LoggerUtil.info(DateUtil.getDay() + "执行开始:" + DateUtil.getTime());
|
|
LoggerUtil.info(DateUtil.getDay() + "执行开始:" + DateUtil.getTime());
|
|
executeBiz(DateUtil.getDay());
|
|
executeBiz(DateUtil.getDay());
|
|
LoggerUtil.info(DateUtil.getDay() + "执行结束:" + DateUtil.getTime());
|
|
LoggerUtil.info(DateUtil.getDay() + "执行结束:" + DateUtil.getTime());
|
|
}
|
|
}
|
|
- // 重新执行最近30天
|
|
|
|
|
|
+ // 11点重新执行最近30天
|
|
if (DateUtil.getHour().equals("11")) {
|
|
if (DateUtil.getHour().equals("11")) {
|
|
for (String day : DateUtil.getSubDateList(DateUtil.getAfterDay(-30), DateUtil.getDay())) {
|
|
for (String day : DateUtil.getSubDateList(DateUtil.getAfterDay(-30), DateUtil.getDay())) {
|
|
LoggerUtil.info(day + "执行开始:" + DateUtil.getTime());
|
|
LoggerUtil.info(day + "执行开始:" + DateUtil.getTime());
|