From b83bdd5eace0698bd7c9d7bcad58e6654db1475f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20=C5=BBak?= Date: Thu, 10 Nov 2022 19:41:11 +0100 Subject: [PATCH] chore: enable interfacebloat linter (#12174) --- .golangci.yml | 1 + metric.go | 1 + plugins/inputs/procstat/process.go | 1 + 3 files changed, 3 insertions(+) diff --git a/.golangci.yml b/.golangci.yml index 466029897..817f6491f 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -14,6 +14,7 @@ linters: - gosimple - govet - ineffassign + - interfacebloat - nakedret - nilerr - predeclared diff --git a/metric.go b/metric.go index 23098bb8b..64b623244 100644 --- a/metric.go +++ b/metric.go @@ -32,6 +32,7 @@ type Field struct { // Metric is the type of data that is processed by Telegraf. Input plugins, // and to a lesser degree, Processor and Aggregator plugins create new Metrics // and Output plugins write them. +// nolint:interfacebloat // conditionally allow to contain more methods type Metric interface { // Name is the primary identifier for the Metric and corresponds to the // measurement in the InfluxDB data model. diff --git a/plugins/inputs/procstat/process.go b/plugins/inputs/procstat/process.go index f31cef4ab..6337e238b 100644 --- a/plugins/inputs/procstat/process.go +++ b/plugins/inputs/procstat/process.go @@ -8,6 +8,7 @@ import ( "github.com/shirou/gopsutil/v3/process" ) +// nolint:interfacebloat // conditionally allow to contain more methods type Process interface { PID() PID Tags() map[string]string