package com.palmnest.webapp.quartz;

import com.palmnest.service.wechat.WeChatAccessManager;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
import org.springframework.stereotype.Controller;

@Slf4j
@Controller
@Component("updateAccessTokenWithOuterUrlTimerTask")
public class UpdateAccessTokenWithOuterUrlTimerTask {


	@Autowired
	private WeChatAccessManager weChatAccessManager;

	public void run() {
		log.info("quartz into UpdateAccessTokenWithOuterUrlTimerTask ...");
		weChatAccessManager.updateAccessTokenWithOuterUrl();
		log.info("quartz into UpdateAccessTokenWithOuterUrlTimerTask end ...");
	}
}
