mirror of
https://github.com/gotenberg/gotenberg.git
synced 2026-08-14 03:12:14 +01:00
improving logging
This commit is contained in:
@@ -1,10 +1,14 @@
|
||||
package pm2
|
||||
|
||||
import (
|
||||
"time"
|
||||
|
||||
"github.com/thecodingmachine/gotenberg/internal/pkg/logger"
|
||||
"github.com/thecodingmachine/gotenberg/internal/pkg/standarderror"
|
||||
)
|
||||
|
||||
const unoconvWarmupTime = 5 * time.Second
|
||||
|
||||
type unoconv struct {
|
||||
manager *processManager
|
||||
}
|
||||
@@ -56,7 +60,13 @@ func (p *unoconv) viable() bool {
|
||||
}
|
||||
|
||||
func (p *unoconv) warmup() {
|
||||
// let's do nothing.
|
||||
const op = "pm2.unoconv.warmup"
|
||||
p.manager.logger.DebugfOp(
|
||||
op,
|
||||
"allowing %v to startup",
|
||||
unoconvWarmupTime,
|
||||
)
|
||||
time.Sleep(unoconvWarmupTime)
|
||||
}
|
||||
|
||||
// Compile-time checks to ensure type implements desired interfaces.
|
||||
|
||||
Reference in New Issue
Block a user