From effe71640daeae0f7e2442176369996bab8fa4ee Mon Sep 17 00:00:00 2001 From: quangz <quangz@bluewisdom.com.cn> Date: 星期三, 27 四月 2022 18:51:47 +0800 Subject: [PATCH] 修复ServerTransaction空指针异常 --- src/main/java/com/genersoft/iot/vmp/gb28181/session/CatalogDataCatch.java | 6 ++++++ 1 files changed, 6 insertions(+), 0 deletions(-) diff --git a/src/main/java/com/genersoft/iot/vmp/gb28181/session/CatalogDataCatch.java b/src/main/java/com/genersoft/iot/vmp/gb28181/session/CatalogDataCatch.java index c3de8a2..97360d2 100644 --- a/src/main/java/com/genersoft/iot/vmp/gb28181/session/CatalogDataCatch.java +++ b/src/main/java/com/genersoft/iot/vmp/gb28181/session/CatalogDataCatch.java @@ -85,6 +85,12 @@ return syncStatus; } + public boolean isSyncRunning(String deviceId) { + CatalogData catalogData = data.get(deviceId); + if (catalogData == null) return false; + return !catalogData.getStatus().equals(CatalogData.CatalogDataStatus.end); + } + @Scheduled(fixedRate = 5 * 1000) //姣�5绉掓墽琛屼竴娆�, 鍙戠幇鏁版嵁5绉掓湭鏇存柊鍒欑Щ闄ゆ暟鎹苟璁や负鏁版嵁鎺ユ敹瓒呮椂 private void timerTask(){ Set<String> keys = data.keySet(); -- Gitblit v1.8.0