Skip to content

Commit 4dcb908

Browse files
ls-2018dims
authored andcommitted
fix: variable naming
Signed-off-by: acejilam <[email protected]>
1 parent 5638b0a commit 4dcb908

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

manager/manager.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ const (
6565
PodmanNamespace = "podman"
6666
)
6767

68-
var HousekeepingConfigFlags = HouskeepingConfig{
68+
var HousekeepingConfigFlags = HousekeepingConfig{
6969
flag.Duration("max_housekeeping_interval", 60*time.Second, "Largest interval to allow between container housekeepings"),
7070
flag.Bool("allow_dynamic_housekeeping", true, "Whether to allow the housekeeping interval to be dynamic"),
7171
}
@@ -147,13 +147,13 @@ type Manager interface {
147147
}
148148

149149
// Housekeeping configuration for the manager
150-
type HouskeepingConfig = struct {
150+
type HousekeepingConfig = struct {
151151
Interval *time.Duration
152152
AllowDynamic *bool
153153
}
154154

155155
// New takes a memory storage and returns a new manager.
156-
func New(memoryCache *memory.InMemoryCache, sysfs sysfs.SysFs, houskeepingConfig HouskeepingConfig, includedMetricsSet container.MetricSet, collectorHTTPClient *http.Client, rawContainerCgroupPathPrefixWhiteList, containerEnvMetadataWhiteList []string, perfEventsFile string, resctrlInterval time.Duration) (Manager, error) {
156+
func New(memoryCache *memory.InMemoryCache, sysfs sysfs.SysFs, HousekeepingConfig HousekeepingConfig, includedMetricsSet container.MetricSet, collectorHTTPClient *http.Client, rawContainerCgroupPathPrefixWhiteList, containerEnvMetadataWhiteList []string, perfEventsFile string, resctrlInterval time.Duration) (Manager, error) {
157157
if memoryCache == nil {
158158
return nil, fmt.Errorf("manager requires memory storage")
159159
}
@@ -200,8 +200,8 @@ func New(memoryCache *memory.InMemoryCache, sysfs sysfs.SysFs, houskeepingConfig
200200
cadvisorContainer: selfContainer,
201201
inHostNamespace: inHostNamespace,
202202
startupTime: time.Now(),
203-
maxHousekeepingInterval: *houskeepingConfig.Interval,
204-
allowDynamicHousekeeping: *houskeepingConfig.AllowDynamic,
203+
maxHousekeepingInterval: *HousekeepingConfig.Interval,
204+
allowDynamicHousekeeping: *HousekeepingConfig.AllowDynamic,
205205
includedMetrics: includedMetricsSet,
206206
containerWatchers: []watcher.ContainerWatcher{},
207207
eventsChannel: eventsChannel,

summary/summary.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ func (s *StatsSummary) AddSample(stat v1.ContainerStats) error {
7878
}
7979
if elapsed > 60*time.Second {
8080
// Make a minute sample. This works with dynamic housekeeping as long
81-
// as we keep max dynamic houskeeping period close to a minute.
81+
// as we keep max dynamic housekeeping period close to a minute.
8282
minuteSample := GetMinutePercentiles(s.secondSamples)
8383
// Clear seconds samples. Keep the latest sample for continuity.
8484
// Copying and resizing helps avoid slice re-allocation.

0 commit comments

Comments
 (0)