Commit 38b7dd87343825967eaf4fa98e240c149e50b9ab
1 parent
e388939e
update...
Showing
3 changed files
with
18 additions
and
1 deletions
src/main/java/com/bsth/StartCommand.java
| ... | ... | @@ -41,7 +41,7 @@ public class StartCommand implements CommandLineRunner{ |
| 41 | 41 | //定时从调度系统刷新进出场数据 |
| 42 | 42 | sexec.scheduleWithFixedDelay(schInOutDataRefreshThread, 40, 60, TimeUnit.SECONDS); |
| 43 | 43 | //定时从调度系统刷新车辆正在的执行班次 |
| 44 | - sexec.scheduleWithFixedDelay(execSchDataRefreshThread, 20, 60 * 3, TimeUnit.SECONDS); | |
| 44 | + sexec.scheduleWithFixedDelay(execSchDataRefreshThread, 20, 60, TimeUnit.SECONDS); | |
| 45 | 45 | //定时刷新实时gps缓存 |
| 46 | 46 | Application.mainServices.scheduleWithFixedDelay(gpsRefreshThread, 10, 7, TimeUnit.SECONDS); |
| 47 | 47 | ... | ... |
src/main/java/com/bsth/server_rs/schedule/real/SchRealDataBuffer.java
| ... | ... | @@ -6,6 +6,7 @@ import com.google.common.collect.ArrayListMultimap; |
| 6 | 6 | import org.apache.commons.lang3.StringUtils; |
| 7 | 7 | import org.springframework.stereotype.Component; |
| 8 | 8 | |
| 9 | +import java.util.Collection; | |
| 9 | 10 | import java.util.List; |
| 10 | 11 | import java.util.Map; |
| 11 | 12 | |
| ... | ... | @@ -66,4 +67,8 @@ public class SchRealDataBuffer { |
| 66 | 67 | public JSONObject getExecPlan(String nbbm) { |
| 67 | 68 | return execMap.get(nbbm); |
| 68 | 69 | } |
| 70 | + | |
| 71 | + public Collection<JSONObject> execs() { | |
| 72 | + return execMap.values(); | |
| 73 | + } | |
| 69 | 74 | } | ... | ... |
src/main/java/com/bsth/server_rs/schedule/real/ScheduleRealService.java
| ... | ... | @@ -164,6 +164,18 @@ public class ScheduleRealService { |
| 164 | 164 | } |
| 165 | 165 | |
| 166 | 166 | /** |
| 167 | + * 获取全部的 车辆 和班次对照信息 | |
| 168 | + * | |
| 169 | + * @param | |
| 170 | + * @return | |
| 171 | + */ | |
| 172 | + @GET | |
| 173 | + @Path("/execs") | |
| 174 | + public Collection<JSONObject> execs(){ | |
| 175 | + return schRealDataBuffer.execs(); | |
| 176 | + } | |
| 177 | + | |
| 178 | + /** | |
| 167 | 179 | * 获取当天指定停车场的进出场排班数据(潘钊场站VIP特供版 -高实时) |
| 168 | 180 | * |
| 169 | 181 | * @return | ... | ... |