Skip to content

Commit

Permalink
LogMemoryStats on debug level
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelsutton committed Apr 3, 2022
1 parent 194b99e commit 2f2a706
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion infrastructure/logger/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ func LogAndMeasureExecutionTime(log *Logger, functionName string) (onEnd func())

// LogMemoryStats logs memory stats for `functionName`
func LogMemoryStats(log *Logger, functionName string) {
log.Trace(NewLogClosure(func() string {
log.Debug(NewLogClosure(func() string {
stats := runtime.MemStats{}
runtime.ReadMemStats(&stats)
return fmt.Sprintf("%s: used memory: %d bytes, total: %d bytes", functionName,
Expand Down

0 comments on commit 2f2a706

Please sign in to comment.