MCPcopy
hub / github.com/cubefs/cubefs / init

Function init

metanode/multi_ver_test.go:94–107  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

92}
93
94func init() {
95 cfg := config.LoadConfigString(cfgJSON)
96
97 logDir := cfg.GetString(ConfigKeyLogDir)
98 os.RemoveAll(logDir)
99
100 clusterEnableSnapshot = true
101
102 if _, err := log.InitLog(logDir, "metanode", log.DebugLevel, nil, log.DefaultLogLeftSpaceLimitRatio); err != nil {
103 fmt.Println("Fatal: failed to start the cubefs daemon - ", err)
104 return
105 }
106 log.LogDebugf("action start")
107}
108
109func initMp(t *testing.T) {
110 tlog = t

Callers

nothing calls this directly

Calls 6

LoadConfigStringFunction · 0.92
InitLogFunction · 0.92
LogDebugfFunction · 0.92
PrintlnMethod · 0.65
GetStringMethod · 0.45
RemoveAllMethod · 0.45

Tested by

no test coverage detected