新增:ES文档数据手动刷新

This commit is contained in:
liuzhaotian
2024-10-24 10:44:43 +08:00
parent d77c6964db
commit 032745ee54
6 changed files with 39 additions and 20 deletions
@@ -27,8 +27,7 @@ import java.io.IOException;
import java.util.*;
import java.util.stream.Collectors;
import static com.cf.imes.framework.common.exception.enums.GlobalErrorCodeConstants.ES_ERROR_DELETE;
import static com.cf.imes.framework.common.exception.enums.GlobalErrorCodeConstants.INTERNAL_SERVER_ERROR;
import static com.cf.imes.framework.common.exception.enums.GlobalErrorCodeConstants.*;
import static com.cf.imes.framework.common.exception.util.ServiceExceptionUtil.exception;
import static com.cf.imes.framework.common.util.object.BeanUtils.toBean;
import static com.cf.imes.module.system.enums.ErrorCodeConstants.DATA_SOURCE_NOT_EXISTS;
@@ -788,7 +787,7 @@ public class DataSourceServiceImpl implements DataSourceService {
log.info("Deleted {} documents with planId {}", response.deleted(), machineId);
} catch (IOException e) {
log.error("Error deleting documents with planId {}: {}", machineId, e.getMessage());
throw new ServiceException(ES_ERROR_DELETE);
throw new ServiceException(ES_DATA_ERROR);
}
}