fix #2738 return ids
This commit is contained in:
parent
5c3d14409e
commit
62325bfbe5
1 changed files with 3 additions and 1 deletions
|
@ -1182,7 +1182,7 @@ public class SearchEngineClient implements Client {
|
|||
}
|
||||
}
|
||||
|
||||
public void addAll(final String index, final List<Map<String, Object>> docList,
|
||||
public String[] addAll(final String index, final List<Map<String, Object>> docList,
|
||||
final BiConsumer<Map<String, Object>, IndexRequestBuilder> options) {
|
||||
final FessConfig fessConfig = ComponentUtil.getFessConfig();
|
||||
final BulkRequestBuilder bulkRequestBuilder = client.prepareBulk();
|
||||
|
@ -1210,6 +1210,8 @@ public class SearchEngineClient implements Client {
|
|||
}
|
||||
throw new SearchEngineClientException(response.buildFailureMessage());
|
||||
}
|
||||
|
||||
return Arrays.stream(response.getItems()).map(res -> res.getId()).toArray(n -> new String[n]);
|
||||
}
|
||||
|
||||
public static class SearchConditionBuilder {
|
||||
|
|
Loading…
Add table
Reference in a new issue