replication master side

This commit is contained in:
finley
2022-11-21 23:36:35 +08:00
parent a7a3da6e49
commit ba7ea942cb
23 changed files with 886 additions and 217 deletions

View File

@@ -107,6 +107,13 @@ func Error(v ...interface{}) {
logger.Println(v...)
}
func Errorf(format string, v ...interface{}) {
mu.Lock()
defer mu.Unlock()
setPrefix(ERROR)
logger.Println(fmt.Sprintf(format, v...))
}
// Fatal prints error log then stop the program
func Fatal(v ...interface{}) {
mu.Lock()