#
Junjie
16 小时以前 ade2ee628437d38cb7c11dd456a5ea18dff97325
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
package com.zy.asrs.task;
 
import com.zy.asrs.service.StationCycleCapacityService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;
 
@Component
public class StationCycleCapacityScheduler {
 
    @Autowired
    private StationCycleCapacityService stationCycleCapacityService;
 
    // 每秒刷新一次循环圈承载量
    @Scheduled(cron = "0/1 * * * * ? ")
    public void refreshStationCycleCapacity() {
        stationCycleCapacityService.refreshSnapshot();
    }
}