Commit a4b17a75 authored by zhangwanglin's avatar zhangwanglin

删掉无用的类

parent 5d854ede
package com.hungraim.ltc.api;
import com.hungraim.ltc.util.Result;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
/**
* @author zwl
* @ClassName SrvTaskFeignService
* @description
* @date 2023/2/27 15:11
**/
@FeignClient("LTC-GOVERNANCE-SERVICE")
public interface SrvTaskFeignService {
@GetMapping("/api.governance/srvTask/timeAllocationSrvTask")
Result timeAllocationSrvTask();
}
package com.hungraim.ltc.system.service.impl;
package com.hungraim.ltc.governance.service;
import com.hungraim.ltc.api.SrvTaskFeignService;
import com.hungraim.ltc.util.Result;
import lombok.AllArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Service;
......@@ -11,20 +9,20 @@ import org.springframework.stereotype.Service;
* @author zwl
* @ClassName SrvTaskScheduledServiceImpl
* @description
* @date 2023/3/1 17:05
* @date 2023/3/2 14:37
**/
@Service
@Slf4j
@AllArgsConstructor
public class SrvTaskScheduledServiceImpl {
private final SrvTaskFeignService srvTaskFeignService;
@Autowired
private SrvTaskService srvTaskService;
@Scheduled(cron = "30 18 20 * * ?")
@Scheduled(cron = "30 30 23 * * ?")
public void timeAllocationSrvTask() {
log.info("timeAllocationSrvTask========start");
Result result = srvTaskFeignService.timeAllocationSrvTask();
log.info("timeAllocationSrvTask========end:{}",result);
srvTaskService.timeAllocationSrvTask();
log.info("timeAllocationSrvTask========end:{}");
}
}
......@@ -65,11 +65,6 @@
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<dependency>
<groupId>com.hungraim.ltc</groupId>
<artifactId>governance</artifactId>
<version>0.0.1</version>
</dependency>
</dependencies>
<build>
......
spring:
main:
#允许存在多个Feign调用相同Service的接口
allow-bean-definition-overriding: true
devtools:
restart:
enabled: true
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment