File tree Expand file tree Collapse file tree 2 files changed +2
-14
lines changed Expand file tree Collapse file tree 2 files changed +2
-14
lines changed Original file line number Diff line number Diff line change 8
8
"github.com/metal-toolbox/ironlib/actions"
9
9
"github.com/sirupsen/logrus"
10
10
11
- "github.com/metal-toolbox/alloy/internal/app"
12
11
"github.com/metal-toolbox/alloy/internal/model"
13
12
)
14
13
@@ -21,13 +20,8 @@ type Queryor struct {
21
20
22
21
// New returns an inband inventory collector
23
22
func NewQueryor (logger * logrus.Logger ) * Queryor {
24
- loggerEntry := app .NewLogrusEntryFromLogger (
25
- logrus.Fields {"component" : "queryor.inband" },
26
- logger ,
27
- )
28
-
29
23
return & Queryor {
30
- logger : loggerEntry ,
24
+ logger : logger . WithFields (logrus. Fields { "component" : "queryor.inband" }) ,
31
25
}
32
26
}
33
27
Original file line number Diff line number Diff line change @@ -18,7 +18,6 @@ import (
18
18
"go.opentelemetry.io/otel/codes"
19
19
"go.opentelemetry.io/otel/trace"
20
20
21
- "github.com/metal-toolbox/alloy/internal/app"
22
21
"github.com/metal-toolbox/alloy/internal/metrics"
23
22
"github.com/metal-toolbox/alloy/internal/model"
24
23
)
@@ -64,18 +63,13 @@ type BMCQueryor interface {
64
63
65
64
// NewQueryor returns a instance of the Queryor inventory collector
66
65
func NewQueryor (logger * logrus.Logger ) * Queryor {
67
- loggerEntry := app .NewLogrusEntryFromLogger (
68
- logrus.Fields {"component" : "collector.outofband" },
69
- logger ,
70
- )
71
-
72
66
lt , err := time .ParseDuration (logoutTimeout )
73
67
if err != nil {
74
68
panic (err )
75
69
}
76
70
77
71
c := & Queryor {
78
- logger : loggerEntry ,
72
+ logger : logger . WithFields (logrus. Fields { "component" : "collector.outofband" }) ,
79
73
logoutTimeout : lt ,
80
74
}
81
75
You can’t perform that action at this time.
0 commit comments