From 7a1e4d9fe3fe2172d5c4fba524f17ffd73ffbb3e Mon Sep 17 00:00:00 2001
From: linwe <872216996@qq.com>
Date: Mon, 08 Jul 2024 10:39:26 +0800
Subject: [PATCH] 公安添加时间过滤
---
src/main/java/org/springblade/es/service/ElasticsearchDocumentService.java | 34 +++++++++++++++++-----------------
1 files changed, 17 insertions(+), 17 deletions(-)
diff --git a/src/main/java/org/springblade/es/service/ElasticsearchDocumentService.java b/src/main/java/org/springblade/es/service/ElasticsearchDocumentService.java
index 41eb0ad..0be652d 100644
--- a/src/main/java/org/springblade/es/service/ElasticsearchDocumentService.java
+++ b/src/main/java/org/springblade/es/service/ElasticsearchDocumentService.java
@@ -173,9 +173,9 @@
// 刷新索引,确保文档可搜索
client.indices().refresh(new RefreshRequest(esParam.getIndexName()), RequestOptions.DEFAULT);
} catch (IOException e) {
- e.printStackTrace();
+// e.printStackTrace();
}
- System.out.println("批量插入结果: " + !bulkResponse.hasFailures());
+// System.out.println("批量插入结果: " + !bulkResponse.hasFailures());
}
}
// 返回
@@ -226,9 +226,9 @@
// 刷新索引,确保文档可搜索
client.indices().refresh(new RefreshRequest(esParam.getIndexName()), RequestOptions.DEFAULT);
} catch (IOException e) {
- e.printStackTrace();
+// e.printStackTrace();
}
- System.out.println("批量插入结果: " + !bulkResponse.hasFailures());
+// System.out.println("批量插入结果: " + !bulkResponse.hasFailures());
}
}
// 返回
@@ -278,9 +278,9 @@
// 刷新索引,确保文档可搜索
client.indices().refresh(new RefreshRequest(esParam.getIndexName()), RequestOptions.DEFAULT);
} catch (IOException e) {
- e.printStackTrace();
+// e.printStackTrace();
}
- System.out.println("批量插入结果: " + !bulkResponse.hasFailures());
+// System.out.println("批量插入结果: " + !bulkResponse.hasFailures());
}
}
// 返回
@@ -329,9 +329,9 @@
// 刷新索引,确保文档可搜索
client.indices().refresh(new RefreshRequest(esParam.getIndexName()), RequestOptions.DEFAULT);
} catch (IOException e) {
- e.printStackTrace();
+// e.printStackTrace();
}
- System.out.println("批量插入结果: " + !bulkResponse.hasFailures());
+// System.out.println("批量插入结果: " + !bulkResponse.hasFailures());
}
}
// 返回
@@ -363,7 +363,7 @@
"articleType", article.getArticleType()
);
} catch (IOException e) {
- e.printStackTrace();
+// e.printStackTrace();
}
}
}
@@ -389,7 +389,7 @@
"communityCode", placeService.getCommunityCode(place.getId())
);
} catch (IOException e) {
- e.printStackTrace();
+// e.printStackTrace();
}
}
}
@@ -415,7 +415,7 @@
"communityCode", houseService.getCommunityCode(house.getId())
);
} catch (IOException e) {
- e.printStackTrace();
+// e.printStackTrace();
}
}
}
@@ -442,7 +442,7 @@
"communityCode", householdService.getCommunityCode(household.getId())
);
} catch (IOException e) {
- e.printStackTrace();
+// e.printStackTrace();
}
}
}
@@ -619,9 +619,9 @@
// 输出操作结果
boolean acknowledged = deleteResponse.isAcknowledged();
- System.out.println("索引删除成功: " + acknowledged);
+// System.out.println("索引删除成功: " + acknowledged);
} catch (IOException e) {
- e.printStackTrace();
+// e.printStackTrace();
}
}
}
@@ -639,7 +639,7 @@
try {
indexDocument(esParam.getIndexName(), str);
} catch (IOException e) {
- e.printStackTrace();
+// e.printStackTrace();
}
return true;
}
@@ -689,7 +689,7 @@
// 刷新索引,确保文档可搜索
client.indices().refresh(new RefreshRequest(esParam.getIndexName()), RequestOptions.DEFAULT);
} catch (IOException e) {
- e.printStackTrace();
+// e.printStackTrace();
}
}
}
@@ -773,7 +773,7 @@
BulkByScrollResponse bulkResponse =
client.deleteByQuery(deleteByQueryRequest, RequestOptions.DEFAULT);
} catch (IOException e) {
- e.printStackTrace();
+// e.printStackTrace();
}
}
return true;
--
Gitblit v1.9.3