wuyunfeng commented on code in PR #10391:
URL: https://github.com/apache/doris/pull/10391#discussion_r906641833


##########
fe/fe-core/src/main/java/org/apache/doris/external/elasticsearch/MappingPhase.java:
##########
@@ -45,7 +45,7 @@ public MappingPhase(EsRestClient client) {
 
     @Override
     public void preProcess(SearchContext context) {
-        if (context.version() != null && 
context.version().onOrAfter(EsMajorVersion.V_7_X)) {
+        if (context.version() != null && 
context.version().on(EsMajorVersion.V_7_X)) {

Review Comment:
   Remove this `prePrcess`



##########
fe/fe-core/src/main/java/org/apache/doris/planner/EsScanNode.java:
##########
@@ -250,7 +251,10 @@ private List<TScanRangeLocations> getShardLocations() 
throws UserException {
                 TEsScanRange esScanRange = new TEsScanRange();
                 esScanRange.setEsHosts(shardAllocations);
                 esScanRange.setIndex(shardRouting.get(0).getIndexName());
-                esScanRange.setType(table.getMappingType());
+                // 8.x type is cancelled
+                if (table.majorVersion == null || 
table.majorVersion.before(EsMajorVersion.V_8_X)) {

Review Comment:
   Don't rely on this, don't issue this parameter directly, BE will do the 
empty judgment processing
   



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to