diff --git a/zlt-business/search-center/search-server/pom.xml b/zlt-business/search-center/search-server/pom.xml
index 035cdf0dd7a5aa8548b01c0c4d9cca205ac723ef..c726ea33f9a54fc97d86f42764c2252cd0b9d73a 100644
--- a/zlt-business/search-center/search-server/pom.xml
+++ b/zlt-business/search-center/search-server/pom.xml
@@ -14,14 +14,22 @@
com.zlt
zlt-config
+
com.zlt
zlt-common-spring-boot-starter
+
com.zlt
search-client
+
+
+ com.zlt
+ zlt-elasticsearch-spring-boot-starter
+
+
org.springframework.boot
spring-boot-starter-web
@@ -31,6 +39,7 @@
com.alibaba.cloud
spring-cloud-starter-alibaba-nacos-discovery
+
com.baomidou
mybatis-plus-extension
@@ -51,11 +60,6 @@
io.micrometer
micrometer-registry-prometheus
-
-
- org.springframework.boot
- spring-boot-starter-data-elasticsearch
-
diff --git a/zlt-business/search-center/search-server/src/main/java/com/central/admin/controller/IndexController.java b/zlt-business/search-center/search-server/src/main/java/com/central/admin/controller/IndexController.java
index c55e0d5585e6a135550ef6cbc4f5ac33405f284e..6104be2d4cd75c3b061348a7b256c71a0b1e675c 100644
--- a/zlt-business/search-center/search-server/src/main/java/com/central/admin/controller/IndexController.java
+++ b/zlt-business/search-center/search-server/src/main/java/com/central/admin/controller/IndexController.java
@@ -1,7 +1,6 @@
package com.central.admin.controller;
import com.central.admin.model.IndexDto;
-import com.central.admin.model.IndexVo;
import com.central.admin.properties.IndexProperties;
import com.central.admin.service.IIndexService;
import com.central.common.model.PageResult;
@@ -11,6 +10,7 @@ import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
+import java.io.IOException;
import java.util.*;
/**
@@ -30,7 +30,7 @@ public class IndexController {
private IndexProperties indexProperties;
@PostMapping("/index")
- public Result createIndex(@RequestBody IndexDto indexDto) {
+ public Result createIndex(@RequestBody IndexDto indexDto) throws IOException {
if (indexDto.getNumberOfShards() == null) {
indexDto.setNumberOfShards(1);
}
@@ -45,7 +45,7 @@ public class IndexController {
* 索引列表
*/
@GetMapping("/indices")
- public PageResult list(@RequestParam(required = false) String queryStr) {
+ public PageResult