New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
os/bluestore: misc cleanups #10201
os/bluestore: misc cleanups #10201
Conversation
97101ae
to
0cc9781
Compare
@@ -1465,6 +1465,8 @@ void BlueStore::_set_compression() | |||
} | |||
} | |||
comp_mode = m; | |||
if (comp_mode == COMP_NONE) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Probably it's better to avoid compressor allocation at all if mode is inappropriate. I.e. calculate the mode first and then proceed with allocation
0cc9781
to
20cd3a4
Compare
@ifed01 Done, please check again! |
derr << __func__ << " unable to initialize " << alg << " compressor" | ||
<< dendl; | ||
} | ||
CompressionMode m; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One can omit this and use comp_mode directly...
Some day we might want make this interface more applicable by handling the abnormal cases more gracefully... Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
We are going to break anyway. Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
Signed-off-by: xie xingguo <xie.xingguo@zte.com.cn>
b63dc58
to
ff03296
Compare
@ifed01 Upgraded again as per your gorgeous ideas. Please check, thanks! |
No description provided.