[legacy bugfix] auto retry major compaction with forced flat store format on encoding estimate size overflow error detected

This commit is contained in:
saltonz
2023-04-20 07:41:39 +00:00
committed by ob-robot
parent 75e30dfb3e
commit 0cf07239dd
12 changed files with 144 additions and 27 deletions

View File

@ -669,6 +669,13 @@ int ObMicroBlockEncoder::build_block(char *&buf, int64_t &size)
} else {
// Print status of current encoders for debugging
print_micro_block_encoder_status();
if (OB_BUF_NOT_ENOUGH == ret) {
// buffer not enough when building a block with pivoted rows, probably caused by estimate
// maximum block size after encoding failed, rewrite errno with OB_ENCODING_EST_SIZE_OVERFLOW
// to force compaction task retry with flat row store type.
ret = OB_ENCODING_EST_SIZE_OVERFLOW;
LOG_WARN("build block failed by probably estimated maximum encoding data size overflow", K(ret));
}
}
if (OB_SUCC(ret)) {