You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by "SaintBacchus (via GitHub)" <gi...@apache.org> on 2023/03/07 06:41:20 UTC
[GitHub] [doris] SaintBacchus commented on a diff in pull request #17502: [fix](DOE)Fix es p0 case error
SaintBacchus commented on code in PR #17502:
URL: https://github.com/apache/doris/pull/17502#discussion_r1127400518
##########
fe/fe-core/src/main/java/org/apache/doris/external/elasticsearch/EsUtil.java:
##########
@@ -169,13 +181,15 @@ public static List<Column> genColumnsFromEs(EsRestClient client, String indexNam
boolean mappingEsId) {
String mapping = client.getMapping(indexName);
ObjectNode mappings = getMapping(mapping);
- ObjectNode rootSchema = getRootSchema(mappings, mappingType);
- return genColumnsFromEs(indexName, mappingType, rootSchema, mappingEsId);
+ // Get array_fields while removing _meta property.
+ List<String> arrayFields = new ArrayList<>();
+ ObjectNode rootSchema = getRootSchema(mappings, mappingType, arrayFields);
Review Comment:
This methon is a bit like C++ style. How about this?
```suggestion
List<String> arrayFields = extractArrayFields(mappings, mappingType);
ObjectNode rootSchema = getRootSchema(mappings, mappingType);
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org