csun5285 commented on code in PR #67642:
URL: https://github.com/apache/doris/pull/67642#discussion_r4003846832
##########
be/src/storage/index/zone_map/zone_map_index.cpp:
##########
@@ -85,6 +87,17 @@ Status ZoneMap::from_proto(const ZoneMapPB& zone_map, const
DataTypePtr& data_ty
parse_bound(zone_map.max(), zone_map_info.max_value);
}
+ // Lower the raised byte back to what the data held, then run the
writer's check on it.
+ // A max that came from 0xff wrapped to 0x00, and old segments still
carry such a max.
+ if (!zone_map_info.pass_all && is_string_type(field_type) &&
+ zone_map.max().size() == MAX_ZONE_MAP_INDEX_SIZE) {
+ std::string max_before_raise = zone_map.max();
+ max_before_raise.back() -= 1;
+ if (!validate_utf8(max_before_raise.data(),
max_before_raise.size())) {
+ zone_map_info.pass_all = true;
Review Comment:
不修改写入侧,改了写入,没办法降级了
--
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]