TokenTask.java 425 B

123456789101112131415161718192021222324252627
  1. package com.jjt.task;
  2. import com.jjt.utils.IotService;
  3. import org.springframework.stereotype.Component;
  4. import javax.annotation.Resource;
  5. /**
  6. * token定时任务
  7. *
  8. * @author wukai
  9. * @date 2025-1-17 23:28:32
  10. */
  11. @Component("token")
  12. public class TokenTask {
  13. @Resource
  14. private IotService iotService;
  15. /**
  16. * 设置iot Token到redis
  17. */
  18. public void iot() {
  19. iotService.setToken();
  20. }
  21. }