[#240] logs: Move log messages to constants
Drop duplicate entities. Format entities. Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com> Signed-off-by: Evgenii Stratonikov <e.stratonikov@yadro.com>
This commit is contained in:
parent
d29b13454f
commit
0e31c12e63
149 changed files with 1481 additions and 687 deletions
|
@ -5,6 +5,7 @@ import (
|
|||
"errors"
|
||||
"sync"
|
||||
|
||||
"git.frostfs.info/TrueCloudLab/frostfs-node/internal/logs"
|
||||
"git.frostfs.info/TrueCloudLab/frostfs-node/pkg/local_object_storage/blobstor/common"
|
||||
storagelog "git.frostfs.info/TrueCloudLab/frostfs-node/pkg/local_object_storage/internal/log"
|
||||
meta "git.frostfs.info/TrueCloudLab/frostfs-node/pkg/local_object_storage/metabase"
|
||||
|
@ -54,7 +55,7 @@ func (c *cache) initFlushMarks() {
|
|||
var errStopIter = errors.New("stop iteration")
|
||||
|
||||
func (c *cache) fsTreeFlushMarkUpdate() {
|
||||
c.log.Info("filling flush marks for objects in FSTree")
|
||||
c.log.Info(logs.WritecacheFillingFlushMarksForObjectsInFSTree)
|
||||
|
||||
var prm common.IteratePrm
|
||||
prm.LazyHandler = func(addr oid.Address, _ func() ([]byte, error)) error {
|
||||
|
@ -86,11 +87,11 @@ func (c *cache) fsTreeFlushMarkUpdate() {
|
|||
return nil
|
||||
}
|
||||
_, _ = c.fsTree.Iterate(prm)
|
||||
c.log.Info("finished updating FSTree flush marks")
|
||||
c.log.Info(logs.WritecacheFinishedUpdatingFSTreeFlushMarks)
|
||||
}
|
||||
|
||||
func (c *cache) dbFlushMarkUpdate() {
|
||||
c.log.Info("filling flush marks for objects in database")
|
||||
c.log.Info(logs.WritecacheFillingFlushMarksForObjectsInDatabase)
|
||||
|
||||
var m []string
|
||||
var indices []int
|
||||
|
@ -158,7 +159,7 @@ func (c *cache) dbFlushMarkUpdate() {
|
|||
lastKey = append([]byte(m[len(m)-1]), 0)
|
||||
}
|
||||
|
||||
c.log.Info("finished updating flush marks")
|
||||
c.log.Info(logs.WritecacheFinishedUpdatingFlushMarks)
|
||||
}
|
||||
|
||||
// flushStatus returns info about the object state in the main storage.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue