Browse Source

[update]0.2版本

xiahailong 2 years ago
parent
commit
2688ead0f7

+ 12 - 2
.idea/workspace.xml

@@ -172,7 +172,10 @@
       <workItem from="1675730151616" duration="2482000" />
       <workItem from="1675751880629" duration="13334000" />
       <workItem from="1675788186214" duration="4782000" />
-      <workItem from="1675817188436" duration="9229000" />
+      <workItem from="1675817188436" duration="9379000" />
+      <workItem from="1675829258696" duration="25000" />
+      <workItem from="1675839509239" duration="2028000" />
+      <workItem from="1675844180241" duration="4797000" />
     </task>
     <task id="LOCAL-00001" summary="[insert]新增prod环境配置,完善es连接配置">
       <created>1675652041715</created>
@@ -216,7 +219,14 @@
       <option name="project" value="LOCAL" />
       <updated>1675824149842</updated>
     </task>
-    <option name="localTasksCounter" value="7" />
+    <task id="LOCAL-00007" summary="[update]0.2版本">
+      <created>1675829124942</created>
+      <option name="number" value="00007" />
+      <option name="presentableId" value="LOCAL-00007" />
+      <option name="project" value="LOCAL" />
+      <updated>1675829124942</updated>
+    </task>
+    <option name="localTasksCounter" value="8" />
     <servers />
   </component>
   <component name="TypeScriptGeneratedFilesManager">

+ 10 - 7
fusion-analysis/src/main/java/cn/com/taiji/service/impl/FusionAnalysisServiceImpl.java

@@ -431,9 +431,10 @@ public class FusionAnalysisServiceImpl implements FusionAnalysisService {
                     SearchHit[] hits2 = searchHits2.getHits();
                     if (hits2.length > 0) {
                         JSONObject sourceItem = JSONObject.parseObject(hits2[0].getSourceAsString());
+                        JSONObject sourceItem2 = JSONObject.parseObject(hits2[hits2.length-1].getSourceAsString());
                         data.setMergeTarget(sourceItem.getString("mergeTarget"));
-                        data.setStartTime(query.getStartTime());
-                        data.setEndTime(query.getEndTime());
+                        data.setStartTime(sourceItem.getString("mergeTime"));
+                        data.setEndTime(sourceItem2.getString("mergeTime"));
                         data.setBatchNumber(item.getBatchNumber());
                         data.setOriginalCount(item.getCount());
                         data.setTrackCount(totalHits);
@@ -540,9 +541,10 @@ public class FusionAnalysisServiceImpl implements FusionAnalysisService {
                     SearchHit[] hits2 = searchHits2.getHits();
                     if (hits2.length > 0) {
                         JSONObject sourceItem = JSONObject.parseObject(hits2[0].getSourceAsString());
+                        JSONObject sourceItem2 = JSONObject.parseObject(hits2[hits2.length-1].getSourceAsString());
                         data.setMergeTarget(sourceItem.getString("mergeTarget"));
-                        data.setStartTime(query.getStartTime());
-                        data.setEndTime(query.getEndTime());
+                        data.setStartTime(sourceItem.getString("mergeTime"));
+                        data.setEndTime(sourceItem2.getString("mergeTime"));
                         data.setBatchNumber(item.getBatchNumber());
                         data.setOriginalCount(item.getCount());
                         data.setTrackCount(totalHits);
@@ -649,9 +651,10 @@ public class FusionAnalysisServiceImpl implements FusionAnalysisService {
                     SearchHit[] hits2 = searchHits2.getHits();
                     if (hits2.length > 0) {
                         JSONObject sourceItem = JSONObject.parseObject(hits2[0].getSourceAsString());
+                        JSONObject sourceItem2 = JSONObject.parseObject(hits2[hits2.length-1].getSourceAsString());
                         data.setMergeTarget(sourceItem.getString("mergeTarget"));
-                        data.setStartTime(query.getStartTime());
-                        data.setEndTime(query.getEndTime());
+                        data.setStartTime(sourceItem.getString("mergeTime"));
+                        data.setEndTime(sourceItem2.getString("mergeTime"));
                         data.setBatchNumber(item.getBatchNumber());
                         data.setOriginalCount(item.getCount());
                         data.setTrackCount(totalHits);
@@ -686,7 +689,7 @@ public class FusionAnalysisServiceImpl implements FusionAnalysisService {
         BoolQueryBuilder boolQueryBuilder = QueryBuilders.boolQuery();
         SearchSourceBuilder searchSourceBuilder = new SearchSourceBuilder();
         boolQueryBuilder.filter(QueryBuilders.rangeQuery("receiveTime").gte(query.getStartTime()).lte(query.getEndTime()));
-        boolQueryBuilder.filter(QueryBuilders.termQuery("targetProper","1"));
+        boolQueryBuilder.mustNot(QueryBuilders.termQuery("targetProper","0"));
         searchSourceBuilder.query(boolQueryBuilder);
 //        TermsAggregationBuilder aggBuilder = AggregationBuilders.terms("ship_field_agg")
 //                .field("fusionBatchNum")