empiredan commented on code in PR #2374:
URL: 
https://github.com/apache/incubator-pegasus/pull/2374#discussion_r2945391269


##########
src/server/pegasus_server_impl.cpp:
##########
@@ -2750,7 +2750,9 @@ void pegasus_server_impl::update_app_envs_before_open_db(
     update_rocksdb_iteration_threshold(envs);
     update_validate_partition_hash(envs);
     update_user_specified_compaction(envs);
-    _manual_compact_svc.start_manual_compact_if_needed(envs);
+    if(_db){

Review Comment:
   As pointed out by @acelyc111-bot , the code style here does not look 
correct. For some reason, the code style lint did not run, and neither the 
build nor unit test workflows were triggered. Please fix the code style and 
resubmit the changes so we can see whether the CI runs properly this time.
   
   Also, please add some comments here to explain that the reason for checking 
`_db != nullptr` is that performing a manual compaction on a follower table 
that is not yet ready for duplication may lead to a segmentation fault.
   
   ```suggestion
       if (_db != nullptr) {
   ```



-- 
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]

Reply via email to