acelyc111 commented on code in PR #1208:
URL: 
https://github.com/apache/incubator-pegasus/pull/1208#discussion_r1007079430


##########
src/replica/mutation_log.cpp:
##########
@@ -939,58 +939,68 @@ error_code mutation_log::reset_from(const std::string 
&dir,
                                     replay_callback replay_error_callback,
                                     io_failure_callback write_error_callback)
 {
-    error_code err = ERR_FILE_OPERATION_FAILED;
-
-    // close for flushing current log and be ready to open new log files after 
reset
+    // Close for flushing current log and get ready to open new log files 
after reset.
     close();
 
-    // make sure logs in `dir` (such as /learn) are valid.
+    // Ensure that log files in `dir` (such as "/learn") are valid.
     error_s es = log_utils::check_log_files_continuity(dir);
     if (!es.is_ok()) {
-        LOG_ERROR_F("the log of source dir {} is invalid:{}, will remove it.", 
dir, es);
+        LOG_ERROR_F("the log files of source dir {} are invalid: {}, will 
remove it", dir, es);
         if (!utils::filesystem::remove_path(dir)) {

Review Comment:
   If remove file failed, there maybe some terrible error of the disk, would it 
better to mark this disk as error?
   We can leave an issue for it and deal with it in the future.



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