ÎļþÃû´Ó igds-basic/src/main/java/com/ld/igds/timer/WeatherScheduled.java ÐÞ¸Ä |
| | |
| | | import org.springframework.http.HttpHeaders; |
| | | import org.springframework.http.HttpMethod; |
| | | import org.springframework.http.converter.StringHttpMessageConverter; |
| | | import org.springframework.scheduling.annotation.Scheduled; |
| | | import org.springframework.stereotype.Component; |
| | | import org.springframework.web.client.RestTemplate; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.nio.charset.StandardCharsets; |
| | | import java.util.ArrayList; |
| | |
| | | */ |
| | | @Slf4j |
| | | @Component |
| | | public class WeatherScheduled { |
| | | public class WeatherTimerService { |
| | | |
| | | @Resource(name = NotifyWeatherService.BEAN_ID) |
| | | private NotifyWeatherService notifyService; |
| | |
| | | /** |
| | | * 宿¶è·åæ°è±¡ä¿¡æ¯ï¼è¯·æ³¨æï¼ç±äºæ°è±¡æ¯æå¤ç½åèªå®ä¹æ°è±¡ç«ï¼ç³»ç»é»è®¤åªæ§è¡å
¶ä¸ä¸ç§æ¹å¼ |
| | | */ |
| | | @Scheduled(cron = "0 0/30 * * * ?") |
| | | public void scheduled() { |
| | | public void doExe() { |
| | | |
| | | log.info("===========================ç³»ç»å®æ¶è·è·åæ°è±¡ä¿¡æ¯======================"); |
| | | |
| | |
| | | |
| | | /** |
| | | * è·å身份认è¯çææaccessToken |
| | | * |
| | | * @param conf |
| | | * @return |
| | | */ |
| | |
| | | return token; |
| | | } |
| | | |
| | | |
| | | } |