4 changed files with 28 additions and 58 deletions
@ -1,43 +0,0 @@ |
|||||
package com.elink.esua.epdc.task.user; |
|
||||
|
|
||||
import com.alibaba.fastjson.JSONObject; |
|
||||
import com.elink.esua.epdc.dto.ScreenIndexBasicDataParamDTO; |
|
||||
import com.elink.esua.epdc.dto.screen.form.ScreenJobFormDTO; |
|
||||
import com.elink.esua.epdc.feign.AnalysisFeignClient; |
|
||||
import com.elink.esua.epdc.feign.UserFeignClient; |
|
||||
import com.elink.esua.epdc.task.screen.ScreenIndexDataPushTask; |
|
||||
import org.apache.commons.lang3.StringUtils; |
|
||||
import org.slf4j.Logger; |
|
||||
import org.slf4j.LoggerFactory; |
|
||||
import org.springframework.beans.factory.annotation.Autowired; |
|
||||
import org.springframework.stereotype.Component; |
|
||||
|
|
||||
/** |
|
||||
* 用户模块 |
|
||||
* |
|
||||
* @Author:liuchuang |
|
||||
* @Date:2020/9/9 15:19 |
|
||||
*/ |
|
||||
@Component("screenUserPointsResetTask") |
|
||||
public class ScreenUserPointsResetImpl implements ScreenUserPointsResetTask { |
|
||||
|
|
||||
private final Logger logger = LoggerFactory.getLogger(getClass()); |
|
||||
|
|
||||
@Autowired |
|
||||
private UserFeignClient userFeignClient; |
|
||||
|
|
||||
@Override |
|
||||
public void run() { |
|
||||
// 用户季度积分重置
|
|
||||
resetUserPoints(); |
|
||||
} |
|
||||
|
|
||||
public void resetUserPoints() { |
|
||||
// 方法名
|
|
||||
String methodName = Thread.currentThread().getStackTrace()[2].getMethodName(); |
|
||||
logger.info("<" + methodName + "|用户积分季度重置>定时任务开始"); |
|
||||
userFeignClient.resetPoints(); |
|
||||
logger.info("<" + methodName + "|用户积分季度重置>定时任务结束"); |
|
||||
} |
|
||||
|
|
||||
} |
|
||||
@ -1,19 +1,32 @@ |
|||||
package com.elink.esua.epdc.task.user; |
package com.elink.esua.epdc.task.user; |
||||
|
|
||||
|
import com.elink.esua.epdc.feign.UserFeignClient; |
||||
|
import com.elink.esua.epdc.task.ITask; |
||||
|
import org.slf4j.Logger; |
||||
|
import org.slf4j.LoggerFactory; |
||||
|
import org.springframework.beans.factory.annotation.Autowired; |
||||
|
import org.springframework.stereotype.Component; |
||||
|
|
||||
/** |
/** |
||||
* 用户积分重置模块 |
* 用户积分重置模块 |
||||
* |
* |
||||
* @Author:liuchuang |
* @Author:liuchuang |
||||
* @Date:2020/9/9 15:20 |
* @Date:2020/9/9 15:20 |
||||
*/ |
*/ |
||||
public interface ScreenUserPointsResetTask { |
@Component("screenUserPointsResetTask") |
||||
|
public class ScreenUserPointsResetTask implements ITask { |
||||
|
|
||||
|
private final Logger logger = LoggerFactory.getLogger(getClass()); |
||||
|
|
||||
|
@Autowired |
||||
|
private UserFeignClient userFeignClient; |
||||
|
|
||||
/** |
@Override |
||||
* 用户积分重置模块 |
public void run(String param) { |
||||
* @param param 入参 |
// 方法名
|
||||
* @return void |
String methodName = Thread.currentThread().getStackTrace()[2].getMethodName(); |
||||
* @author syp |
logger.info("<" + methodName + "|用户积分季度重置>定时任务开始"); |
||||
* @since 2020/9/9 15:21 |
userFeignClient.resetPoints(); |
||||
*/ |
logger.info("<" + methodName + "|用户积分季度重置>定时任务结束"); |
||||
void run(); |
} |
||||
} |
} |
||||
|
|||||
Loading…
Reference in new issue