Closed stupidstan closed 2 years ago
请问这个用例预期一直不停吗
loop {
for i in 1024
}
append_compact_purge.rs用例好像不会执行压缩
The compression is done inside engine.write(&batch)
. More specifically, here:
https://github.com/tikv/raft-engine/blob/7a436eae40a6b62371123c96941e058b7fe52b63/src/log_batch.rs#L709-L718
If the data is larger than compression_threshold
(8KB by default), the block will be compressed.
state.last_index一直是0,不会走到70行
There's an issue with this example. The state.last_index
should be incremented before written via engine.write(&batch)
.
Feel free to file an PR to fix it.
请问这个用例预期一直不停吗
Yes, you have to manually kill it. Maybe we can do something to improve it later.
append_compact_purge.rs用例好像不会执行压缩
The compression is done inside
engine.write(&batch)
. More specifically, here:If the data is larger than
compression_threshold
(8KB by default), the block will be compressed.state.last_index一直是0,不会走到70行
There's an issue with this example. The
state.last_index
should be incremented before written viaengine.write(&batch)
.Feel free to file an PR to fix it.
请问这个用例预期一直不停吗
Yes, you have to manually kill it. Maybe we can do something to improve it later.
感谢答疑~
state.last_index一直是0,不会走到70行