瀏覽代碼

推送化验检查迁移代码添加日志

kongwz 6 年之前
父節點
當前提交
57a6dffba4
共有 1 個文件被更改,包括 15 次插入1 次删除
  1. 15 1
      graphdb/src/main/java/org/diagbot/service/impl/KnowledgeServiceImpl.java

+ 15 - 1
graphdb/src/main/java/org/diagbot/service/impl/KnowledgeServiceImpl.java

@@ -13,6 +13,8 @@ import org.diagbot.vo.domain.FeatureRate;
 import org.diagbot.vo.domain.SearchData;
 import org.neo4j.driver.v1.types.Node;
 import org.neo4j.driver.v1.types.Path;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.data.domain.PageRequest;
 import org.springframework.data.domain.Pageable;
@@ -24,7 +26,7 @@ import java.util.*;
 
 @Service
 public class KnowledgeServiceImpl implements KnowledgeService {
-
+    Logger logger = LoggerFactory.getLogger(KnowledgeServiceImpl.class);
     @Autowired
     private SymptomRepository symptomRepository;
     @Autowired
@@ -199,8 +201,10 @@ public class KnowledgeServiceImpl implements KnowledgeService {
             for (FeatureRate fe:bigdataDiagFeature) {
                 if("neo4j".equals(fe.getRate())){
                     bigdataDiagList.add(fe.getFeatureName());
+                    logger.info("图谱推出的诊断为: "+fe.getFeatureName());
                 }else {
                     bigdataDiagList.add(fe.getFeatureName());
+                    logger.info("大数据推出的诊断为: "+fe.getFeatureName());
                 }
             }
         }
@@ -211,6 +215,8 @@ public class KnowledgeServiceImpl implements KnowledgeService {
                 }
             }
         }
+        logger.info("界面诊断为: " + webDiagList);
+        logger.info("推出的诊断合并为: " + bigdataDiagList);
         Map<String, Set<String>> weblisPacs =null;
         Map<String, Set<String>> biglisPacs =null;
         if(webDiagList !=null && webDiagList.size()>0){
@@ -225,16 +231,24 @@ public class KnowledgeServiceImpl implements KnowledgeService {
         if(weblisPacs !=null && weblisPacs.values().size()>0){
             lis = weblisPacs.get("LIS");
             pacs = weblisPacs.get("PACS");
+            logger.info("界面有诊断的情况下,界面诊断推出的lis为: "+lis);
+            logger.info("界面有诊断的情况下,界面诊断推出的pacs为: "+pacs);
             if(biglisPacs !=null && biglisPacs.values().size()>0){
                 Set<String> bl = biglisPacs.get("LIS");
                 Set<String>  bp= biglisPacs.get("PACS");
+                logger.info("界面有诊断的情况下,推出诊断的lis为: "+bl);
+                logger.info("界面有诊断的情况下,推出诊断的pacs为: "+bp);
                 lis.addAll(bl);
                 pacs.addAll(bp);
             }
         }else {
             lis = biglisPacs.get("LIS");
             pacs = biglisPacs.get("PACS");
+            logger.info("界面无诊断的情况下,推出诊断的lis为: "+lis);
+            logger.info("界面无诊断的情况下,推出诊断的lis为: "+pacs);
         }
+        logger.info("推出的合并lis为: " + lis);
+        logger.info("推出的合并pacs为: " + pacs);
         ArrayList<FeatureRate> lisFeature = new ArrayList<>();
         ArrayList<FeatureRate> pacsFeature = new ArrayList<>();
         for (String l:lis) {