| 23723 |
amit.gupta |
1 |
package com.smartdukaan.cron.config;
|
|
|
2 |
|
|
|
3 |
import java.text.SimpleDateFormat;
|
|
|
4 |
import java.util.Date;
|
|
|
5 |
import java.util.HashMap;
|
|
|
6 |
import java.util.Map;
|
|
|
7 |
|
|
|
8 |
import org.slf4j.Logger;
|
|
|
9 |
import org.slf4j.LoggerFactory;
|
|
|
10 |
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
11 |
import org.springframework.context.annotation.ComponentScan;
|
|
|
12 |
import org.springframework.scheduling.annotation.Scheduled;
|
|
|
13 |
import org.springframework.stereotype.Component;
|
|
|
14 |
|
|
|
15 |
import com.spice.profitmandi.common.enumuration.SchemeType;
|
|
|
16 |
import com.spice.profitmandi.common.web.client.RestClient;
|
|
|
17 |
|
|
|
18 |
@Component
|
|
|
19 |
@ComponentScan("com.smartdukaan.cron.*")
|
|
|
20 |
@ComponentScan("com.spice.profitmandi.common.*")
|
|
|
21 |
public class ScheduledTasks {
|
|
|
22 |
|
|
|
23 |
private static final Logger log = LoggerFactory.getLogger(ScheduledTasks.class);
|
|
|
24 |
|
|
|
25 |
private static final SimpleDateFormat dateFormat = new SimpleDateFormat("HH:mm:ss");
|
|
|
26 |
|
|
|
27 |
@Autowired
|
|
|
28 |
private RestClient restClient;
|
|
|
29 |
|
|
|
30 |
/*@Scheduled(fixedRate = 5000)
|
|
|
31 |
public void reportCurrentTime() {
|
|
|
32 |
log.info("The time is now {}", dateFormat.format(new Date()));
|
|
|
33 |
}*/
|
|
|
34 |
}
|