mrproliu opened a new pull request, #13910: URL: https://github.com/apache/skywalking/pull/13910
### Improve the efficiency of BanyanDB hot → warm → cold lifecycle stage migration (default config) Each coarser lifecycle stage's `segmentInterval` should be an integer multiple of the immediately finer (preceding) stage's. BanyanDB segments are epoch-anchored, so when the coarser interval is a multiple of the finer one, every source segment nests entirely inside exactly one target segment and the tier migration stays on the cheap **whole-segment fast path** (byte-copy). A non-multiple interval makes source segments straddle target boundaries, forcing a row-by-row decode-and-re-bucket **slow path** that costs significantly more CPU, IO, and peak memory, and produces more small parts for the background merge loop to compact. It does not affect correctness — only migration efficiency. This aligns the shipped defaults that previously violated the rule: | Group | Field | Old → New | |-------|-------|-----------| | records | cold `segmentInterval` | 3 → 4 (multiple of warm=2) | | metricsMinute | cold `segmentInterval` | 5 → 6 (multiple of warm=3) | | metricsHour | warm `segmentInterval` | 7 → 10 (multiple of hot=5) | | metricsHour | cold `segmentInterval` | 15 → 20 (multiple of warm=10) | All adjusted values still satisfy `hot ≤ warm ≤ cold` and `segmentInterval ≤ that stage's ttl`. The other groups already comply and are unchanged. - [x] The improvement is structural (whole-segment byte-copy vs row-by-row re-bucketing), not a micro-optimization, so no micro-benchmark applies; the fast/slow path mechanism is documented in the stages guide. - [x] Theory proof: see the new "integer multiple" guideline in `docs/en/banyandb/stages.md`, and the BanyanDB migration fast/slow path behavior. - [ ] If this pull request closes/resolves/fixes an existing issue, replace the issue number. Closes #<issue number>. - [x] Update the [`CHANGES` log](https://github.com/apache/skywalking/blob/master/docs/en/changes/changes.md). -- 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]
