Skip to content

Commit

Permalink
update debug log msg & internal pkg
Browse files Browse the repository at this point in the history
  • Loading branch information
ketsiambaku committed Aug 18, 2024
1 parent 2495592 commit 5d5ada1
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions internal/debug/lifecycle.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ type (
// PollerStart collects information on poller start up.
// consumers should provide a concurrency-safe implementation.
PollerStart(workerID string) Run
// ReadPollerCount return the number or running pollers
ReadPollerCount() int32
}

Expand All @@ -70,6 +71,7 @@ func (lc *lifeCycleImpl) ReadPollerCount() int32 {
return lc.pollerCount.Load()
}

// NewLifeCycle creates a new LifeCycle instance
func NewLifeCycle() LifeCycle { return &lifeCycleImpl{} }

var _ LifeCycle = &lifeCycleImpl{}
Expand Down
2 changes: 1 addition & 1 deletion internal/internal_worker.go
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ func ensureRequiredParams(params *workerExecutionParameters) {
}
if params.EventMonitoring.LifeCycle == nil {
params.EventMonitoring.LifeCycle = debug.NewLifeCycle()
params.Logger.Debug("No PollerLifeCycle configured for cadence worker. Use default one.")
params.Logger.Debug("No LifeCycle configured for EventMonitoring option. Use default one.")
}
}

Expand Down
2 changes: 1 addition & 1 deletion internal/worker.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import (
"context"
"time"

"go.uber.org/cadence/debug"
"go.uber.org/cadence/internal/debug"

"github.com/opentracing/opentracing-go"
"github.com/uber-go/tally"
Expand Down

0 comments on commit 5d5ada1

Please sign in to comment.