From 2e7826783aac5c8328e1d5b0567a407a600216b2 Mon Sep 17 00:00:00 2001 From: Ziqi Zhao Date: Thu, 5 May 2022 21:04:30 +0800 Subject: [PATCH] enable errcheck and exclude all components which are not passing. (#9726) * add errcheck to golangci-lint config, and exclude all components which are not passing. Signed-off-by: Ziqi Zhao * fix missing issues for linux Signed-off-by: Ziqi Zhao * fix missing issues for linux Signed-off-by: Ziqi Zhao --- .golangci.yml | 3 +-- examples/demo/server/main.go | 1 + exporter/awscloudwatchlogsexporter/exporter.go | 1 + exporter/awscloudwatchlogsexporter/exporter_test.go | 1 + exporter/awsemfexporter/emf_exporter.go | 1 + exporter/awsemfexporter/grouped_metric_test.go | 1 + exporter/awsemfexporter/metric_declaration_test.go | 1 + exporter/awsemfexporter/metric_translator_test.go | 1 + exporter/awsxrayexporter/awsxray_test.go | 1 + exporter/awsxrayexporter/internal/translator/cause.go | 1 + .../awsxrayexporter/internal/translator/writer_pool_test.go | 1 + exporter/carbonexporter/exporter_test.go | 1 + exporter/coralogixexporter/config_test.go | 1 + exporter/datadogexporter/factory_test.go | 1 + exporter/datadogexporter/internal/metrics/consumer_test.go | 1 + .../datadogexporter/internal/model/translator/sketches_test.go | 1 + exporter/datadogexporter/internal/testutils/test_utils.go | 1 + exporter/datadogexporter/traces_exporter.go | 1 + exporter/datadogexporter/traces_exporter_test.go | 1 + exporter/dynatraceexporter/metrics_exporter_test.go | 1 + exporter/elasticexporter/exporter_test.go | 1 + .../elasticexporter/internal/translator/elastic/metadata.go | 1 + exporter/elasticsearchexporter/exporter.go | 1 + exporter/elasticsearchexporter/exporter_test.go | 1 + exporter/elasticsearchexporter/internal/objmodel/objmodel.go | 1 + exporter/googlecloudexporter/legacymetrics.go | 1 + exporter/googlecloudexporter/legacymetrics_test.go | 1 + exporter/honeycombexporter/honeycomb.go | 1 + exporter/honeycombexporter/honeycomb_test.go | 1 + exporter/humioexporter/humio_client.go | 1 + exporter/jaegerthrifthttpexporter/exporter.go | 1 + exporter/loadbalancingexporter/factory.go | 1 + exporter/loadbalancingexporter/loadbalancer.go | 1 + exporter/loadbalancingexporter/loadbalancer_test.go | 1 + exporter/loadbalancingexporter/log_exporter_test.go | 1 + exporter/loadbalancingexporter/resolver_dns_test.go | 1 + exporter/loadbalancingexporter/resolver_static.go | 1 + exporter/loadbalancingexporter/resolver_static_test.go | 1 + exporter/loadbalancingexporter/trace_exporter_test.go | 1 + exporter/newrelicexporter/factory.go | 1 + exporter/newrelicexporter/newrelic.go | 1 + exporter/prometheusexporter/prometheus_test.go | 1 + exporter/prometheusremotewriteexporter/wal_test.go | 1 + exporter/sentryexporter/sentry_exporter_test.go | 1 + exporter/signalfxexporter/dpclient.go | 1 + exporter/signalfxexporter/eventclient.go | 1 + exporter/signalfxexporter/exporter_test.go | 1 + exporter/signalfxexporter/factory_test.go | 1 + .../signalfxexporter/internal/correlation/correlation_test.go | 1 + exporter/splunkhecexporter/client.go | 1 + exporter/splunkhecexporter/client_test.go | 2 ++ exporter/sumologicexporter/sender_test.go | 1 + exporter/tanzuobservabilityexporter/metrics_exporter_test.go | 1 + extension/basicauthextension/extension_test.go | 1 + extension/fluentbitextension/process_linux_test.go | 1 + extension/httpforwarder/extension_test.go | 1 + extension/oauth2clientauthextension/extension_test.go | 1 + extension/observer/ecsobserver/internal/errctx/value_test.go | 1 + extension/storage/dbstorage/extension_test.go | 1 + extension/storage/filestorage/client_test.go | 1 + internal/aws/awsutil/conn.go | 1 + internal/aws/cwlogs/pusher_test.go | 1 + internal/aws/k8s/k8sclient/endpoint_test.go | 1 + internal/aws/k8s/k8sclient/job_test.go | 1 + internal/aws/k8s/k8sclient/node_test.go | 1 + internal/aws/k8s/k8sclient/pod_test.go | 1 + internal/aws/k8s/k8sclient/replicaset_test.go | 1 + internal/aws/proxy/server_test.go | 2 +- internal/aws/xray/testdata/sampleapp/sample.go | 1 + internal/aws/xray/testdata/sampleserver/sample.go | 1 + internal/components/extensions_test.go | 1 + internal/containertest/container.go | 1 + internal/docker/docker_test.go | 2 +- internal/scrapertest/golden/golden.go | 1 + internal/scrapertest/golden/golden_test.go | 1 + internal/stanza/converter.go | 1 + internal/stanza/emitter_test.go | 1 + internal/stanza/receiver.go | 1 + internal/stanza/receiver_test.go | 1 + internal/stanza/storage_test.go | 1 + processor/cumulativetodeltaprocessor/processor_test.go | 1 + processor/deltatorateprocessor/factory.go | 1 + processor/deltatorateprocessor/processor_test.go | 1 + processor/groupbytraceprocessor/event.go | 1 + processor/groupbytraceprocessor/processor.go | 1 + processor/groupbytraceprocessor/processor_test.go | 1 + processor/groupbytraceprocessor/storage_memory_test.go | 1 + .../k8sattributesprocessor/internal/kube/informer_test.go | 1 + .../internal/observability/observability.go | 1 + processor/k8sattributesprocessor/options_test.go | 1 + processor/metricsgenerationprocessor/factory.go | 1 + .../metrics_transform_processor_test.go | 1 + .../resourcedetectionprocessor/internal/azure/metadata_test.go | 1 + .../resourcedetectionprocessor/internal/gcp/metadata_test.go | 1 + .../internal/gcp/mockmetadata_test.go | 1 + .../resourcedetection_processor_test.go | 1 + processor/routingprocessor/processor_test.go | 1 + processor/spanmetricsprocessor/processor_test.go | 1 + .../internal/sampling/string_tag_filter_test.go | 1 + processor/tailsamplingprocessor/processor_test.go | 1 + .../internal/cadvisor/cadvisor_linux.go | 1 + .../internal/cadvisor/extractors/fs_extractor_test.go | 1 + .../internal/cadvisor/testutils/helpers.go | 1 + receiver/awscontainerinsightreceiver/receiver.go | 1 + receiver/awscontainerinsightreceiver/receiver_test.go | 2 ++ receiver/awsecscontainermetricsreceiver/receiver.go | 1 + receiver/awsxrayreceiver/internal/translator/translator.go | 1 + receiver/awsxrayreceiver/internal/udppoller/poller_test.go | 1 + receiver/awsxrayreceiver/receiver.go | 1 + receiver/awsxrayreceiver/receiver_test.go | 1 + receiver/carbonreceiver/receiver_test.go | 1 + receiver/carbonreceiver/reporter_test.go | 1 + receiver/collectdreceiver/observability.go | 1 + receiver/collectdreceiver/receiver.go | 1 + receiver/couchbasereceiver/client_test.go | 1 + receiver/couchdbreceiver/client_test.go | 1 + receiver/elasticsearchreceiver/scraper_test.go | 1 + receiver/filelogreceiver/filelog_test.go | 1 + receiver/fluentforwardreceiver/collector.go | 1 + receiver/googlecloudpubsubreceiver/receiver_test.go | 1 + receiver/jmxreceiver/internal/subprocess/subprocess.go | 1 + .../internal/collection/metricsstore_test.go | 1 + receiver/k8sclusterreceiver/receiver_test.go | 1 + receiver/k8sclusterreceiver/watcher.go | 1 + receiver/k8sclusterreceiver/watcher_test.go | 1 + receiver/kafkareceiver/kafka_receiver.go | 1 + receiver/kafkareceiver/kafka_receiver_test.go | 1 + .../kubeletstatsreceiver/internal/kubelet/metadata_test.go | 1 + receiver/mongodbatlasreceiver/internal/mongodb_atlas_client.go | 1 + receiver/mongodbreceiver/scraper_test.go | 1 + .../opencensusreceiver/internal/ocmetrics/opencensus_test.go | 1 + .../opencensusreceiver/internal/octrace/observability_test.go | 1 + .../opencensusreceiver/internal/octrace/opencensus_test.go | 1 + receiver/opencensusreceiver/opencensus_test.go | 1 + receiver/podmanreceiver/receiver_test.go | 1 + receiver/prometheusreceiver/internal/otlp_transaction.go | 1 + receiver/rabbitmqreceiver/client_test.go | 1 + receiver/rabbitmqreceiver/scraper_test.go | 1 + receiver/riakreceiver/client_test.go | 1 + receiver/saphanareceiver/client.go | 1 + receiver/saphanareceiver/queries.go | 1 + receiver/sapmreceiver/trace_receiver.go | 1 + receiver/sapmreceiver/trace_receiver_test.go | 1 + receiver/signalfxreceiver/receiver.go | 1 + receiver/signalfxreceiver/receiver_test.go | 1 + .../examples/federation/prom-counter/main.go | 1 + receiver/splunkhecreceiver/receiver.go | 1 + receiver/splunkhecreceiver/receiver_test.go | 1 + receiver/statsdreceiver/protocol/statsd_parser_test.go | 1 + receiver/statsdreceiver/receiver.go | 1 + receiver/statsdreceiver/receiver_test.go | 1 + receiver/statsdreceiver/reporter_test.go | 1 + receiver/wavefrontreceiver/receiver_test.go | 1 + receiver/zookeeperreceiver/scraper_test.go | 1 + testbed/datareceivers/mockawsxraydatareceiver.go | 1 + .../mockdatareceivers/mockawsxrayreceiver/trace_receiver.go | 1 + tracegen/internal/tracegen/worker.go | 1 + tracegen/main.go | 1 + 158 files changed, 160 insertions(+), 4 deletions(-) diff --git a/.golangci.yml b/.golangci.yml index e7ffefac9d98..00df1a369846 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -94,8 +94,6 @@ linters-settings: - kilometres linters: - disable: - - errcheck enable: - exportloopref - gofmt @@ -107,6 +105,7 @@ linters: - staticcheck - unconvert - unparam + - errcheck issues: # Excluding configuration per-path, per-linter, per-text and per-source diff --git a/examples/demo/server/main.go b/examples/demo/server/main.go index 16ad608e4ba3..7b913e022690 100644 --- a/examples/demo/server/main.go +++ b/examples/demo/server/main.go @@ -13,6 +13,7 @@ // limitations under the License. // Sample contains a simple http server that exports to the OpenTelemetry agent. +// nolint:errcheck package main import ( diff --git a/exporter/awscloudwatchlogsexporter/exporter.go b/exporter/awscloudwatchlogsexporter/exporter.go index 0184558ca96f..593e918b0ae1 100644 --- a/exporter/awscloudwatchlogsexporter/exporter.go +++ b/exporter/awscloudwatchlogsexporter/exporter.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package awscloudwatchlogsexporter // import "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/awscloudwatchlogsexporter" import ( diff --git a/exporter/awscloudwatchlogsexporter/exporter_test.go b/exporter/awscloudwatchlogsexporter/exporter_test.go index 5bee5416a4e0..e12e42d50587 100644 --- a/exporter/awscloudwatchlogsexporter/exporter_test.go +++ b/exporter/awscloudwatchlogsexporter/exporter_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package awscloudwatchlogsexporter import ( diff --git a/exporter/awsemfexporter/emf_exporter.go b/exporter/awsemfexporter/emf_exporter.go index 4bb879ce4b24..019de83f9947 100644 --- a/exporter/awsemfexporter/emf_exporter.go +++ b/exporter/awsemfexporter/emf_exporter.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package awsemfexporter // import "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/awsemfexporter" import ( diff --git a/exporter/awsemfexporter/grouped_metric_test.go b/exporter/awsemfexporter/grouped_metric_test.go index c5f1b06d33b9..aac15ef23c8c 100644 --- a/exporter/awsemfexporter/grouped_metric_test.go +++ b/exporter/awsemfexporter/grouped_metric_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package awsemfexporter import ( diff --git a/exporter/awsemfexporter/metric_declaration_test.go b/exporter/awsemfexporter/metric_declaration_test.go index 4312c0871ee3..924d76cc762d 100644 --- a/exporter/awsemfexporter/metric_declaration_test.go +++ b/exporter/awsemfexporter/metric_declaration_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package awsemfexporter import ( diff --git a/exporter/awsemfexporter/metric_translator_test.go b/exporter/awsemfexporter/metric_translator_test.go index 3e24246ad7bc..159ec984ed2e 100644 --- a/exporter/awsemfexporter/metric_translator_test.go +++ b/exporter/awsemfexporter/metric_translator_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package awsemfexporter import ( diff --git a/exporter/awsxrayexporter/awsxray_test.go b/exporter/awsxrayexporter/awsxray_test.go index bc62bbbd21fb..3a67bdc3269d 100644 --- a/exporter/awsxrayexporter/awsxray_test.go +++ b/exporter/awsxrayexporter/awsxray_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package awsxrayexporter import ( diff --git a/exporter/awsxrayexporter/internal/translator/cause.go b/exporter/awsxrayexporter/internal/translator/cause.go index bb3fc56da461..1ae9534493bb 100644 --- a/exporter/awsxrayexporter/internal/translator/cause.go +++ b/exporter/awsxrayexporter/internal/translator/cause.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package translator // import "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/awsxrayexporter/internal/translator" import ( diff --git a/exporter/awsxrayexporter/internal/translator/writer_pool_test.go b/exporter/awsxrayexporter/internal/translator/writer_pool_test.go index 1b5a582e5cea..0304aa4cd4f5 100644 --- a/exporter/awsxrayexporter/internal/translator/writer_pool_test.go +++ b/exporter/awsxrayexporter/internal/translator/writer_pool_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package translator import ( diff --git a/exporter/carbonexporter/exporter_test.go b/exporter/carbonexporter/exporter_test.go index 52d432137f2c..b97b5bf88229 100644 --- a/exporter/carbonexporter/exporter_test.go +++ b/exporter/carbonexporter/exporter_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package carbonexporter import ( diff --git a/exporter/coralogixexporter/config_test.go b/exporter/coralogixexporter/config_test.go index a2f95acaee49..febd01a34a8f 100644 --- a/exporter/coralogixexporter/config_test.go +++ b/exporter/coralogixexporter/config_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package coralogixexporter // import "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/coralogixexporter" import ( diff --git a/exporter/datadogexporter/factory_test.go b/exporter/datadogexporter/factory_test.go index 0baeee002521..3ef48f11d3d5 100644 --- a/exporter/datadogexporter/factory_test.go +++ b/exporter/datadogexporter/factory_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package datadogexporter import ( diff --git a/exporter/datadogexporter/internal/metrics/consumer_test.go b/exporter/datadogexporter/internal/metrics/consumer_test.go index 03c9df65e5f8..afdc3f15b17a 100644 --- a/exporter/datadogexporter/internal/metrics/consumer_test.go +++ b/exporter/datadogexporter/internal/metrics/consumer_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package metrics import ( diff --git a/exporter/datadogexporter/internal/model/translator/sketches_test.go b/exporter/datadogexporter/internal/model/translator/sketches_test.go index 2511ae02a881..2faa040609b9 100644 --- a/exporter/datadogexporter/internal/model/translator/sketches_test.go +++ b/exporter/datadogexporter/internal/model/translator/sketches_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package translator import ( diff --git a/exporter/datadogexporter/internal/testutils/test_utils.go b/exporter/datadogexporter/internal/testutils/test_utils.go index 908f84680e58..7151e59ebadf 100644 --- a/exporter/datadogexporter/internal/testutils/test_utils.go +++ b/exporter/datadogexporter/internal/testutils/test_utils.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package testutils // import "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/datadogexporter/internal/testutils" import ( diff --git a/exporter/datadogexporter/traces_exporter.go b/exporter/datadogexporter/traces_exporter.go index 55c8f6df80e6..581a460d720f 100644 --- a/exporter/datadogexporter/traces_exporter.go +++ b/exporter/datadogexporter/traces_exporter.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package datadogexporter // import "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/datadogexporter" import ( diff --git a/exporter/datadogexporter/traces_exporter_test.go b/exporter/datadogexporter/traces_exporter_test.go index b8051696f566..3559e598c9f7 100644 --- a/exporter/datadogexporter/traces_exporter_test.go +++ b/exporter/datadogexporter/traces_exporter_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package datadogexporter import ( diff --git a/exporter/dynatraceexporter/metrics_exporter_test.go b/exporter/dynatraceexporter/metrics_exporter_test.go index afd750d04beb..140c43b94d20 100644 --- a/exporter/dynatraceexporter/metrics_exporter_test.go +++ b/exporter/dynatraceexporter/metrics_exporter_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package dynatraceexporter import ( diff --git a/exporter/elasticexporter/exporter_test.go b/exporter/elasticexporter/exporter_test.go index 7ed6db6679a5..3a921a58023f 100644 --- a/exporter/elasticexporter/exporter_test.go +++ b/exporter/elasticexporter/exporter_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package elasticexporter import ( diff --git a/exporter/elasticexporter/internal/translator/elastic/metadata.go b/exporter/elasticexporter/internal/translator/elastic/metadata.go index 661e71c0be88..272014cbdef2 100644 --- a/exporter/elasticexporter/internal/translator/elastic/metadata.go +++ b/exporter/elasticexporter/internal/translator/elastic/metadata.go @@ -13,6 +13,7 @@ // limitations under the License. // Package elastic contains an OTLP exporter for Elastic APM. +// nolint:errcheck package elastic // import "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/elasticexporter/internal/translator/elastic" import ( diff --git a/exporter/elasticsearchexporter/exporter.go b/exporter/elasticsearchexporter/exporter.go index fd70632e234b..a0584e439f70 100644 --- a/exporter/elasticsearchexporter/exporter.go +++ b/exporter/elasticsearchexporter/exporter.go @@ -14,6 +14,7 @@ // Package elasticsearchexporter contains an opentelemetry-collector exporter // for Elasticsearch. +// nolint:errcheck package elasticsearchexporter // import "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/elasticsearchexporter" import ( diff --git a/exporter/elasticsearchexporter/exporter_test.go b/exporter/elasticsearchexporter/exporter_test.go index a9001016c919..c7a183b218ab 100644 --- a/exporter/elasticsearchexporter/exporter_test.go +++ b/exporter/elasticsearchexporter/exporter_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package elasticsearchexporter import ( diff --git a/exporter/elasticsearchexporter/internal/objmodel/objmodel.go b/exporter/elasticsearchexporter/internal/objmodel/objmodel.go index d0ae365ed838..d435d36afbc4 100644 --- a/exporter/elasticsearchexporter/internal/objmodel/objmodel.go +++ b/exporter/elasticsearchexporter/internal/objmodel/objmodel.go @@ -40,6 +40,7 @@ // Ingest Node is used. But either way, we try to present only well formed // document to Elasticsearch. +// nolint:errcheck package objmodel // import "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/elasticsearchexporter/internal/objmodel" import ( diff --git a/exporter/googlecloudexporter/legacymetrics.go b/exporter/googlecloudexporter/legacymetrics.go index 0a3415a10690..de68cbb9e235 100644 --- a/exporter/googlecloudexporter/legacymetrics.go +++ b/exporter/googlecloudexporter/legacymetrics.go @@ -14,6 +14,7 @@ // Package googlecloudexporter contains the wrapper for OpenTelemetry-GoogleCloud // exporter to be used in opentelemetry-collector. +// nolint:errcheck package googlecloudexporter // import "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/googlecloudexporter" import ( diff --git a/exporter/googlecloudexporter/legacymetrics_test.go b/exporter/googlecloudexporter/legacymetrics_test.go index 3ce51dd3fe5c..823c32a4e353 100644 --- a/exporter/googlecloudexporter/legacymetrics_test.go +++ b/exporter/googlecloudexporter/legacymetrics_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package googlecloudexporter import ( diff --git a/exporter/honeycombexporter/honeycomb.go b/exporter/honeycombexporter/honeycomb.go index ee6287be55a5..2fda3d314d40 100644 --- a/exporter/honeycombexporter/honeycomb.go +++ b/exporter/honeycombexporter/honeycomb.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package honeycombexporter // import "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/honeycombexporter" import ( diff --git a/exporter/honeycombexporter/honeycomb_test.go b/exporter/honeycombexporter/honeycomb_test.go index 59982708bb15..1d75dc3c5136 100644 --- a/exporter/honeycombexporter/honeycomb_test.go +++ b/exporter/honeycombexporter/honeycomb_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package honeycombexporter import ( diff --git a/exporter/humioexporter/humio_client.go b/exporter/humioexporter/humio_client.go index e26b0795eaf4..a52d424a41a8 100644 --- a/exporter/humioexporter/humio_client.go +++ b/exporter/humioexporter/humio_client.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package humioexporter // import "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/humioexporter" import ( diff --git a/exporter/jaegerthrifthttpexporter/exporter.go b/exporter/jaegerthrifthttpexporter/exporter.go index bd56c785e53b..6752fe0d2688 100644 --- a/exporter/jaegerthrifthttpexporter/exporter.go +++ b/exporter/jaegerthrifthttpexporter/exporter.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package jaegerthrifthttpexporter // import "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/jaegerthrifthttpexporter" import ( diff --git a/exporter/loadbalancingexporter/factory.go b/exporter/loadbalancingexporter/factory.go index 6efaf4fd0a4f..3a3b83a6eadb 100644 --- a/exporter/loadbalancingexporter/factory.go +++ b/exporter/loadbalancingexporter/factory.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package loadbalancingexporter // import "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/loadbalancingexporter" import ( diff --git a/exporter/loadbalancingexporter/loadbalancer.go b/exporter/loadbalancingexporter/loadbalancer.go index 294babd938f0..022c168bae71 100644 --- a/exporter/loadbalancingexporter/loadbalancer.go +++ b/exporter/loadbalancingexporter/loadbalancer.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package loadbalancingexporter // import "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/loadbalancingexporter" import ( diff --git a/exporter/loadbalancingexporter/loadbalancer_test.go b/exporter/loadbalancingexporter/loadbalancer_test.go index f890ee79a233..c087fd773c08 100644 --- a/exporter/loadbalancingexporter/loadbalancer_test.go +++ b/exporter/loadbalancingexporter/loadbalancer_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package loadbalancingexporter import ( diff --git a/exporter/loadbalancingexporter/log_exporter_test.go b/exporter/loadbalancingexporter/log_exporter_test.go index c152fb9b6e51..4f9171a12fad 100644 --- a/exporter/loadbalancingexporter/log_exporter_test.go +++ b/exporter/loadbalancingexporter/log_exporter_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package loadbalancingexporter import ( diff --git a/exporter/loadbalancingexporter/resolver_dns_test.go b/exporter/loadbalancingexporter/resolver_dns_test.go index b82b356f8832..25bfc155ba0c 100644 --- a/exporter/loadbalancingexporter/resolver_dns_test.go +++ b/exporter/loadbalancingexporter/resolver_dns_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package loadbalancingexporter import ( diff --git a/exporter/loadbalancingexporter/resolver_static.go b/exporter/loadbalancingexporter/resolver_static.go index 4fc8d1fc71a7..4aa903c77453 100644 --- a/exporter/loadbalancingexporter/resolver_static.go +++ b/exporter/loadbalancingexporter/resolver_static.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package loadbalancingexporter // import "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/loadbalancingexporter" import ( diff --git a/exporter/loadbalancingexporter/resolver_static_test.go b/exporter/loadbalancingexporter/resolver_static_test.go index b5e0218959a7..23abedc5f2a9 100644 --- a/exporter/loadbalancingexporter/resolver_static_test.go +++ b/exporter/loadbalancingexporter/resolver_static_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package loadbalancingexporter import ( diff --git a/exporter/loadbalancingexporter/trace_exporter_test.go b/exporter/loadbalancingexporter/trace_exporter_test.go index 250ac8724d10..28fecf4815c0 100644 --- a/exporter/loadbalancingexporter/trace_exporter_test.go +++ b/exporter/loadbalancingexporter/trace_exporter_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package loadbalancingexporter import ( diff --git a/exporter/newrelicexporter/factory.go b/exporter/newrelicexporter/factory.go index 7f6638fd7503..900fb0744add 100644 --- a/exporter/newrelicexporter/factory.go +++ b/exporter/newrelicexporter/factory.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package newrelicexporter // import "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/newrelicexporter" import ( diff --git a/exporter/newrelicexporter/newrelic.go b/exporter/newrelicexporter/newrelic.go index 8c79ce3c884e..04745422ea50 100644 --- a/exporter/newrelicexporter/newrelic.go +++ b/exporter/newrelicexporter/newrelic.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package newrelicexporter // import "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/newrelicexporter" import ( diff --git a/exporter/prometheusexporter/prometheus_test.go b/exporter/prometheusexporter/prometheus_test.go index 5769ec009341..402ada55eaf0 100644 --- a/exporter/prometheusexporter/prometheus_test.go +++ b/exporter/prometheusexporter/prometheus_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package prometheusexporter import ( diff --git a/exporter/prometheusremotewriteexporter/wal_test.go b/exporter/prometheusremotewriteexporter/wal_test.go index 96b729a498b7..7bd96470e028 100644 --- a/exporter/prometheusremotewriteexporter/wal_test.go +++ b/exporter/prometheusremotewriteexporter/wal_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package prometheusremotewriteexporter import ( diff --git a/exporter/sentryexporter/sentry_exporter_test.go b/exporter/sentryexporter/sentry_exporter_test.go index 69cf9f826e4d..8bd56be3af85 100644 --- a/exporter/sentryexporter/sentry_exporter_test.go +++ b/exporter/sentryexporter/sentry_exporter_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package sentryexporter import ( diff --git a/exporter/signalfxexporter/dpclient.go b/exporter/signalfxexporter/dpclient.go index e2ecee6fe35b..3e110e585a5c 100644 --- a/exporter/signalfxexporter/dpclient.go +++ b/exporter/signalfxexporter/dpclient.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package signalfxexporter // import "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/signalfxexporter" import ( diff --git a/exporter/signalfxexporter/eventclient.go b/exporter/signalfxexporter/eventclient.go index a89c15c559dc..053fce856b39 100644 --- a/exporter/signalfxexporter/eventclient.go +++ b/exporter/signalfxexporter/eventclient.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package signalfxexporter // import "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/signalfxexporter" import ( diff --git a/exporter/signalfxexporter/exporter_test.go b/exporter/signalfxexporter/exporter_test.go index d86ea837ffcd..815c3f447350 100644 --- a/exporter/signalfxexporter/exporter_test.go +++ b/exporter/signalfxexporter/exporter_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package signalfxexporter import ( diff --git a/exporter/signalfxexporter/factory_test.go b/exporter/signalfxexporter/factory_test.go index e7dfe92d7170..ddf74f4cf735 100644 --- a/exporter/signalfxexporter/factory_test.go +++ b/exporter/signalfxexporter/factory_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package signalfxexporter import ( diff --git a/exporter/signalfxexporter/internal/correlation/correlation_test.go b/exporter/signalfxexporter/internal/correlation/correlation_test.go index bbe8491228d7..e6dcbe3be706 100644 --- a/exporter/signalfxexporter/internal/correlation/correlation_test.go +++ b/exporter/signalfxexporter/internal/correlation/correlation_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package correlation import ( diff --git a/exporter/splunkhecexporter/client.go b/exporter/splunkhecexporter/client.go index 636b9f5afffd..d16aab76b599 100644 --- a/exporter/splunkhecexporter/client.go +++ b/exporter/splunkhecexporter/client.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package splunkhecexporter // import "github.com/open-telemetry/opentelemetry-collector-contrib/exporter/splunkhecexporter" import ( diff --git a/exporter/splunkhecexporter/client_test.go b/exporter/splunkhecexporter/client_test.go index 6a95e55a1a94..cde05f49c566 100644 --- a/exporter/splunkhecexporter/client_test.go +++ b/exporter/splunkhecexporter/client_test.go @@ -11,6 +11,8 @@ // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. + +// nolint:errcheck package splunkhecexporter import ( diff --git a/exporter/sumologicexporter/sender_test.go b/exporter/sumologicexporter/sender_test.go index 4af63d9527ed..316f137a2f80 100644 --- a/exporter/sumologicexporter/sender_test.go +++ b/exporter/sumologicexporter/sender_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package sumologicexporter import ( diff --git a/exporter/tanzuobservabilityexporter/metrics_exporter_test.go b/exporter/tanzuobservabilityexporter/metrics_exporter_test.go index 31fdec04331b..67af9f1346dc 100644 --- a/exporter/tanzuobservabilityexporter/metrics_exporter_test.go +++ b/exporter/tanzuobservabilityexporter/metrics_exporter_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package tanzuobservabilityexporter import ( diff --git a/extension/basicauthextension/extension_test.go b/extension/basicauthextension/extension_test.go index 569367c43beb..6ce142af322b 100644 --- a/extension/basicauthextension/extension_test.go +++ b/extension/basicauthextension/extension_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package basicauthextension // import "github.com/open-telemetry/opentelemetry-collector-contrib/extension/basicauthextension" import ( diff --git a/extension/fluentbitextension/process_linux_test.go b/extension/fluentbitextension/process_linux_test.go index 74258007c9b1..d34eafd2fec9 100644 --- a/extension/fluentbitextension/process_linux_test.go +++ b/extension/fluentbitextension/process_linux_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package fluentbitextension import ( diff --git a/extension/httpforwarder/extension_test.go b/extension/httpforwarder/extension_test.go index e06a1212a206..eb0142dba4b2 100644 --- a/extension/httpforwarder/extension_test.go +++ b/extension/httpforwarder/extension_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package httpforwarder import ( diff --git a/extension/oauth2clientauthextension/extension_test.go b/extension/oauth2clientauthextension/extension_test.go index 8e46accb7acb..05d0d5951c91 100644 --- a/extension/oauth2clientauthextension/extension_test.go +++ b/extension/oauth2clientauthextension/extension_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package oauth2clientauthextension import ( diff --git a/extension/observer/ecsobserver/internal/errctx/value_test.go b/extension/observer/ecsobserver/internal/errctx/value_test.go index c25062e35c5a..9b9fb789fbf5 100644 --- a/extension/observer/ecsobserver/internal/errctx/value_test.go +++ b/extension/observer/ecsobserver/internal/errctx/value_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package errctx import ( diff --git a/extension/storage/dbstorage/extension_test.go b/extension/storage/dbstorage/extension_test.go index 1d731c1a753e..26ed0ccc22d2 100644 --- a/extension/storage/dbstorage/extension_test.go +++ b/extension/storage/dbstorage/extension_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package dbstorage import ( diff --git a/extension/storage/filestorage/client_test.go b/extension/storage/filestorage/client_test.go index f967e2b4f79c..62b98b572794 100644 --- a/extension/storage/filestorage/client_test.go +++ b/extension/storage/filestorage/client_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package filestorage import ( diff --git a/internal/aws/awsutil/conn.go b/internal/aws/awsutil/conn.go index fe374a12ecde..51d45336e62d 100644 --- a/internal/aws/awsutil/conn.go +++ b/internal/aws/awsutil/conn.go @@ -13,6 +13,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package awsutil // import "github.com/open-telemetry/opentelemetry-collector-contrib/internal/aws/awsutil" import ( diff --git a/internal/aws/cwlogs/pusher_test.go b/internal/aws/cwlogs/pusher_test.go index 9ac511a6387f..969f7c50500c 100644 --- a/internal/aws/cwlogs/pusher_test.go +++ b/internal/aws/cwlogs/pusher_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package cwlogs import ( diff --git a/internal/aws/k8s/k8sclient/endpoint_test.go b/internal/aws/k8s/k8sclient/endpoint_test.go index b09eb55510c4..3bf96f167fea 100644 --- a/internal/aws/k8s/k8sclient/endpoint_test.go +++ b/internal/aws/k8s/k8sclient/endpoint_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package k8sclient import ( diff --git a/internal/aws/k8s/k8sclient/job_test.go b/internal/aws/k8s/k8sclient/job_test.go index 082c997e6501..ab08c243b2ab 100644 --- a/internal/aws/k8s/k8sclient/job_test.go +++ b/internal/aws/k8s/k8sclient/job_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package k8sclient import ( diff --git a/internal/aws/k8s/k8sclient/node_test.go b/internal/aws/k8s/k8sclient/node_test.go index 2d669fed27bd..7a306f9cf2d2 100644 --- a/internal/aws/k8s/k8sclient/node_test.go +++ b/internal/aws/k8s/k8sclient/node_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package k8sclient import ( diff --git a/internal/aws/k8s/k8sclient/pod_test.go b/internal/aws/k8s/k8sclient/pod_test.go index 460510c4f938..441fa872c866 100644 --- a/internal/aws/k8s/k8sclient/pod_test.go +++ b/internal/aws/k8s/k8sclient/pod_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package k8sclient import ( diff --git a/internal/aws/k8s/k8sclient/replicaset_test.go b/internal/aws/k8s/k8sclient/replicaset_test.go index 68fe3135586a..eadeff97fbb3 100644 --- a/internal/aws/k8s/k8sclient/replicaset_test.go +++ b/internal/aws/k8s/k8sclient/replicaset_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package k8sclient import ( diff --git a/internal/aws/proxy/server_test.go b/internal/aws/proxy/server_test.go index 5d922c25e38f..f2a8cc95dc44 100644 --- a/internal/aws/proxy/server_test.go +++ b/internal/aws/proxy/server_test.go @@ -16,7 +16,7 @@ // +build !windows // TODO review if tests should succeed on Windows - +// nolint:errcheck package proxy import ( diff --git a/internal/aws/xray/testdata/sampleapp/sample.go b/internal/aws/xray/testdata/sampleapp/sample.go index 8234a33f5925..bd2fd96c6f21 100644 --- a/internal/aws/xray/testdata/sampleapp/sample.go +++ b/internal/aws/xray/testdata/sampleapp/sample.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package main import ( diff --git a/internal/aws/xray/testdata/sampleserver/sample.go b/internal/aws/xray/testdata/sampleserver/sample.go index f4ee7e9c9280..0ccb2ec47f6d 100644 --- a/internal/aws/xray/testdata/sampleserver/sample.go +++ b/internal/aws/xray/testdata/sampleserver/sample.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package main import ( diff --git a/internal/components/extensions_test.go b/internal/components/extensions_test.go index 1c191e15a4a2..13c93337f3c3 100644 --- a/internal/components/extensions_test.go +++ b/internal/components/extensions_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package components import ( diff --git a/internal/containertest/container.go b/internal/containertest/container.go index 790913eba12c..4affa3cfcb42 100644 --- a/internal/containertest/container.go +++ b/internal/containertest/container.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package containertest // import "github.com/open-telemetry/opentelemetry-collector-contrib/internal/containertest" import ( diff --git a/internal/docker/docker_test.go b/internal/docker/docker_test.go index 29e83404427c..9cab2572a5af 100644 --- a/internal/docker/docker_test.go +++ b/internal/docker/docker_test.go @@ -16,7 +16,7 @@ // +build !windows // TODO review if tests should succeed on Windows - +// nolint:errcheck package docker import ( diff --git a/internal/scrapertest/golden/golden.go b/internal/scrapertest/golden/golden.go index 97f686e2eff3..f69e12bb616e 100644 --- a/internal/scrapertest/golden/golden.go +++ b/internal/scrapertest/golden/golden.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package golden // import "github.com/open-telemetry/opentelemetry-collector-contrib/internal/scrapertest/golden" import ( diff --git a/internal/scrapertest/golden/golden_test.go b/internal/scrapertest/golden/golden_test.go index 3c5d023f9fdf..d9736f38813d 100644 --- a/internal/scrapertest/golden/golden_test.go +++ b/internal/scrapertest/golden/golden_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package golden import ( diff --git a/internal/stanza/converter.go b/internal/stanza/converter.go index 817b66a21cda..dd7b617297e2 100644 --- a/internal/stanza/converter.go +++ b/internal/stanza/converter.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package stanza // import "github.com/open-telemetry/opentelemetry-collector-contrib/internal/stanza" import ( diff --git a/internal/stanza/emitter_test.go b/internal/stanza/emitter_test.go index 12bda3e1aeff..233a606f2e3a 100644 --- a/internal/stanza/emitter_test.go +++ b/internal/stanza/emitter_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package stanza import ( diff --git a/internal/stanza/receiver.go b/internal/stanza/receiver.go index 6694d5f1358b..8568c2a37c35 100644 --- a/internal/stanza/receiver.go +++ b/internal/stanza/receiver.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package stanza // import "github.com/open-telemetry/opentelemetry-collector-contrib/internal/stanza" import ( diff --git a/internal/stanza/receiver_test.go b/internal/stanza/receiver_test.go index e79574e88995..155f548dcb2a 100644 --- a/internal/stanza/receiver_test.go +++ b/internal/stanza/receiver_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package stanza import ( diff --git a/internal/stanza/storage_test.go b/internal/stanza/storage_test.go index cc1328bd355d..ad5b1b4bccee 100644 --- a/internal/stanza/storage_test.go +++ b/internal/stanza/storage_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package stanza import ( diff --git a/processor/cumulativetodeltaprocessor/processor_test.go b/processor/cumulativetodeltaprocessor/processor_test.go index ea3b0f5a7e03..9f2f8ed6855c 100644 --- a/processor/cumulativetodeltaprocessor/processor_test.go +++ b/processor/cumulativetodeltaprocessor/processor_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package cumulativetodeltaprocessor import ( diff --git a/processor/deltatorateprocessor/factory.go b/processor/deltatorateprocessor/factory.go index ab1c95d90b87..6fdf5c44a3f0 100644 --- a/processor/deltatorateprocessor/factory.go +++ b/processor/deltatorateprocessor/factory.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package deltatorateprocessor // import "github.com/open-telemetry/opentelemetry-collector-contrib/processor/deltatorateprocessor" import ( diff --git a/processor/deltatorateprocessor/processor_test.go b/processor/deltatorateprocessor/processor_test.go index 0f5c920cbf22..6117ab1e1031 100644 --- a/processor/deltatorateprocessor/processor_test.go +++ b/processor/deltatorateprocessor/processor_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package deltatorateprocessor import ( diff --git a/processor/groupbytraceprocessor/event.go b/processor/groupbytraceprocessor/event.go index b9b7a9cdd5a6..c295c5b22a53 100644 --- a/processor/groupbytraceprocessor/event.go +++ b/processor/groupbytraceprocessor/event.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package groupbytraceprocessor // import "github.com/open-telemetry/opentelemetry-collector-contrib/processor/groupbytraceprocessor" import ( diff --git a/processor/groupbytraceprocessor/processor.go b/processor/groupbytraceprocessor/processor.go index 686d263cad27..a79b74c9b408 100644 --- a/processor/groupbytraceprocessor/processor.go +++ b/processor/groupbytraceprocessor/processor.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package groupbytraceprocessor // import "github.com/open-telemetry/opentelemetry-collector-contrib/processor/groupbytraceprocessor" import ( diff --git a/processor/groupbytraceprocessor/processor_test.go b/processor/groupbytraceprocessor/processor_test.go index a3a8a332d21a..07a96b87db87 100644 --- a/processor/groupbytraceprocessor/processor_test.go +++ b/processor/groupbytraceprocessor/processor_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package groupbytraceprocessor import ( diff --git a/processor/groupbytraceprocessor/storage_memory_test.go b/processor/groupbytraceprocessor/storage_memory_test.go index 096d98f6b21d..f3e857f46f4c 100644 --- a/processor/groupbytraceprocessor/storage_memory_test.go +++ b/processor/groupbytraceprocessor/storage_memory_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package groupbytraceprocessor import ( diff --git a/processor/k8sattributesprocessor/internal/kube/informer_test.go b/processor/k8sattributesprocessor/internal/kube/informer_test.go index 7920ca3c21ad..4075671fd4b1 100644 --- a/processor/k8sattributesprocessor/internal/kube/informer_test.go +++ b/processor/k8sattributesprocessor/internal/kube/informer_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package kube import ( diff --git a/processor/k8sattributesprocessor/internal/observability/observability.go b/processor/k8sattributesprocessor/internal/observability/observability.go index 4be63c34f77c..ba4147740045 100644 --- a/processor/k8sattributesprocessor/internal/observability/observability.go +++ b/processor/k8sattributesprocessor/internal/observability/observability.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package observability // import "github.com/open-telemetry/opentelemetry-collector-contrib/processor/k8sattributesprocessor/internal/observability" import ( diff --git a/processor/k8sattributesprocessor/options_test.go b/processor/k8sattributesprocessor/options_test.go index 5e5a3e0be240..eb2f37cbc919 100644 --- a/processor/k8sattributesprocessor/options_test.go +++ b/processor/k8sattributesprocessor/options_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package k8sattributesprocessor import ( diff --git a/processor/metricsgenerationprocessor/factory.go b/processor/metricsgenerationprocessor/factory.go index e43ac0329bd0..f2ec8ef0fbb4 100644 --- a/processor/metricsgenerationprocessor/factory.go +++ b/processor/metricsgenerationprocessor/factory.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package metricsgenerationprocessor // import "github.com/open-telemetry/opentelemetry-collector-contrib/processor/metricsgenerationprocessor" import ( diff --git a/processor/metricstransformprocessor/metrics_transform_processor_test.go b/processor/metricstransformprocessor/metrics_transform_processor_test.go index 33603363c98d..20cb1cb2b62d 100644 --- a/processor/metricstransformprocessor/metrics_transform_processor_test.go +++ b/processor/metricstransformprocessor/metrics_transform_processor_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package metricstransformprocessor import ( diff --git a/processor/resourcedetectionprocessor/internal/azure/metadata_test.go b/processor/resourcedetectionprocessor/internal/azure/metadata_test.go index 78009a37242a..a31b6837cdd5 100644 --- a/processor/resourcedetectionprocessor/internal/azure/metadata_test.go +++ b/processor/resourcedetectionprocessor/internal/azure/metadata_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package azure import ( diff --git a/processor/resourcedetectionprocessor/internal/gcp/metadata_test.go b/processor/resourcedetectionprocessor/internal/gcp/metadata_test.go index fb8e2209974c..4d388676f4a3 100644 --- a/processor/resourcedetectionprocessor/internal/gcp/metadata_test.go +++ b/processor/resourcedetectionprocessor/internal/gcp/metadata_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package gcp import ( diff --git a/processor/resourcedetectionprocessor/internal/gcp/mockmetadata_test.go b/processor/resourcedetectionprocessor/internal/gcp/mockmetadata_test.go index 7a1fc28238a0..4996eb2df949 100644 --- a/processor/resourcedetectionprocessor/internal/gcp/mockmetadata_test.go +++ b/processor/resourcedetectionprocessor/internal/gcp/mockmetadata_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package gcp import ( diff --git a/processor/resourcedetectionprocessor/resourcedetection_processor_test.go b/processor/resourcedetectionprocessor/resourcedetection_processor_test.go index 085820d27751..5d3c219e3e90 100644 --- a/processor/resourcedetectionprocessor/resourcedetection_processor_test.go +++ b/processor/resourcedetectionprocessor/resourcedetection_processor_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package resourcedetectionprocessor import ( diff --git a/processor/routingprocessor/processor_test.go b/processor/routingprocessor/processor_test.go index a4f8db927ec4..a37ed5ddb536 100644 --- a/processor/routingprocessor/processor_test.go +++ b/processor/routingprocessor/processor_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package routingprocessor import ( diff --git a/processor/spanmetricsprocessor/processor_test.go b/processor/spanmetricsprocessor/processor_test.go index 7b03145c7463..949b28fc47f7 100644 --- a/processor/spanmetricsprocessor/processor_test.go +++ b/processor/spanmetricsprocessor/processor_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package spanmetricsprocessor import ( diff --git a/processor/tailsamplingprocessor/internal/sampling/string_tag_filter_test.go b/processor/tailsamplingprocessor/internal/sampling/string_tag_filter_test.go index 1afdce2c2d40..7fec9e221645 100644 --- a/processor/tailsamplingprocessor/internal/sampling/string_tag_filter_test.go +++ b/processor/tailsamplingprocessor/internal/sampling/string_tag_filter_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package sampling import ( diff --git a/processor/tailsamplingprocessor/processor_test.go b/processor/tailsamplingprocessor/processor_test.go index 7a1ab90a1a69..81c86fc924de 100644 --- a/processor/tailsamplingprocessor/processor_test.go +++ b/processor/tailsamplingprocessor/processor_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package tailsamplingprocessor import ( diff --git a/receiver/awscontainerinsightreceiver/internal/cadvisor/cadvisor_linux.go b/receiver/awscontainerinsightreceiver/internal/cadvisor/cadvisor_linux.go index 70d1dd9727b1..0442103e1084 100644 --- a/receiver/awscontainerinsightreceiver/internal/cadvisor/cadvisor_linux.go +++ b/receiver/awscontainerinsightreceiver/internal/cadvisor/cadvisor_linux.go @@ -15,6 +15,7 @@ //go:build linux // +build linux +// nolint:errcheck package cadvisor // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/awscontainerinsightreceiver/internal/cadvisor" import ( diff --git a/receiver/awscontainerinsightreceiver/internal/cadvisor/extractors/fs_extractor_test.go b/receiver/awscontainerinsightreceiver/internal/cadvisor/extractors/fs_extractor_test.go index 5e823b3f15e0..b7aeb3a27c75 100644 --- a/receiver/awscontainerinsightreceiver/internal/cadvisor/extractors/fs_extractor_test.go +++ b/receiver/awscontainerinsightreceiver/internal/cadvisor/extractors/fs_extractor_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package extractors import ( diff --git a/receiver/awscontainerinsightreceiver/internal/cadvisor/testutils/helpers.go b/receiver/awscontainerinsightreceiver/internal/cadvisor/testutils/helpers.go index 64d9d300cef6..275436b47201 100644 --- a/receiver/awscontainerinsightreceiver/internal/cadvisor/testutils/helpers.go +++ b/receiver/awscontainerinsightreceiver/internal/cadvisor/testutils/helpers.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package testutils // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/awscontainerinsightreceiver/internal/cadvisor/testutils" import ( diff --git a/receiver/awscontainerinsightreceiver/receiver.go b/receiver/awscontainerinsightreceiver/receiver.go index b2ceec9945bb..6fba1ec91273 100644 --- a/receiver/awscontainerinsightreceiver/receiver.go +++ b/receiver/awscontainerinsightreceiver/receiver.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package awscontainerinsightreceiver // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/awscontainerinsightreceiver" import ( diff --git a/receiver/awscontainerinsightreceiver/receiver_test.go b/receiver/awscontainerinsightreceiver/receiver_test.go index 91c7ec87372e..827f4d00acef 100644 --- a/receiver/awscontainerinsightreceiver/receiver_test.go +++ b/receiver/awscontainerinsightreceiver/receiver_test.go @@ -11,6 +11,8 @@ // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. + +// nolint:errcheck package awscontainerinsightreceiver import ( diff --git a/receiver/awsecscontainermetricsreceiver/receiver.go b/receiver/awsecscontainermetricsreceiver/receiver.go index ba5405ef8aca..7b19f583ccb9 100644 --- a/receiver/awsecscontainermetricsreceiver/receiver.go +++ b/receiver/awsecscontainermetricsreceiver/receiver.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package awsecscontainermetricsreceiver // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/awsecscontainermetricsreceiver" import ( diff --git a/receiver/awsxrayreceiver/internal/translator/translator.go b/receiver/awsxrayreceiver/internal/translator/translator.go index e76c411bb2c2..1ad1425f16b5 100644 --- a/receiver/awsxrayreceiver/internal/translator/translator.go +++ b/receiver/awsxrayreceiver/internal/translator/translator.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package translator // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/awsxrayreceiver/internal/translator" import ( diff --git a/receiver/awsxrayreceiver/internal/udppoller/poller_test.go b/receiver/awsxrayreceiver/internal/udppoller/poller_test.go index 3b618b3ff525..e91f6be9a970 100644 --- a/receiver/awsxrayreceiver/internal/udppoller/poller_test.go +++ b/receiver/awsxrayreceiver/internal/udppoller/poller_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package udppoller import ( diff --git a/receiver/awsxrayreceiver/receiver.go b/receiver/awsxrayreceiver/receiver.go index 024415e5d159..442f58f2e77d 100644 --- a/receiver/awsxrayreceiver/receiver.go +++ b/receiver/awsxrayreceiver/receiver.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package awsxrayreceiver // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/awsxrayreceiver" import ( diff --git a/receiver/awsxrayreceiver/receiver_test.go b/receiver/awsxrayreceiver/receiver_test.go index 055fa2eb9314..3e8312efac12 100644 --- a/receiver/awsxrayreceiver/receiver_test.go +++ b/receiver/awsxrayreceiver/receiver_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package awsxrayreceiver import ( diff --git a/receiver/carbonreceiver/receiver_test.go b/receiver/carbonreceiver/receiver_test.go index 0f3409813d86..08e5a07dab3d 100644 --- a/receiver/carbonreceiver/receiver_test.go +++ b/receiver/carbonreceiver/receiver_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package carbonreceiver import ( diff --git a/receiver/carbonreceiver/reporter_test.go b/receiver/carbonreceiver/reporter_test.go index 437b16398d8f..5586de2ff309 100644 --- a/receiver/carbonreceiver/reporter_test.go +++ b/receiver/carbonreceiver/reporter_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package carbonreceiver import ( diff --git a/receiver/collectdreceiver/observability.go b/receiver/collectdreceiver/observability.go index 699ea249b861..1c8f43e082ac 100644 --- a/receiver/collectdreceiver/observability.go +++ b/receiver/collectdreceiver/observability.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package collectdreceiver // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/collectdreceiver" import ( diff --git a/receiver/collectdreceiver/receiver.go b/receiver/collectdreceiver/receiver.go index a49fac384830..9d55735ee61d 100644 --- a/receiver/collectdreceiver/receiver.go +++ b/receiver/collectdreceiver/receiver.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package collectdreceiver // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/collectdreceiver" import ( diff --git a/receiver/couchbasereceiver/client_test.go b/receiver/couchbasereceiver/client_test.go index bf807e8755cb..3ca325f8ee89 100644 --- a/receiver/couchbasereceiver/client_test.go +++ b/receiver/couchbasereceiver/client_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package couchbasereceiver import ( diff --git a/receiver/couchdbreceiver/client_test.go b/receiver/couchdbreceiver/client_test.go index a72b01879e0f..dba0dd4190fe 100644 --- a/receiver/couchdbreceiver/client_test.go +++ b/receiver/couchdbreceiver/client_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package couchdbreceiver // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/couchdbreceiver" import ( diff --git a/receiver/elasticsearchreceiver/scraper_test.go b/receiver/elasticsearchreceiver/scraper_test.go index 10cd6c15b1b6..94cdc0a5c869 100644 --- a/receiver/elasticsearchreceiver/scraper_test.go +++ b/receiver/elasticsearchreceiver/scraper_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package elasticsearchreceiver import ( diff --git a/receiver/filelogreceiver/filelog_test.go b/receiver/filelogreceiver/filelog_test.go index ff371b2c85cd..64edb0dc8f19 100644 --- a/receiver/filelogreceiver/filelog_test.go +++ b/receiver/filelogreceiver/filelog_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package filelogreceiver import ( diff --git a/receiver/fluentforwardreceiver/collector.go b/receiver/fluentforwardreceiver/collector.go index 9c243001d27b..0607d7afd95a 100644 --- a/receiver/fluentforwardreceiver/collector.go +++ b/receiver/fluentforwardreceiver/collector.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package fluentforwardreceiver // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/fluentforwardreceiver" import ( diff --git a/receiver/googlecloudpubsubreceiver/receiver_test.go b/receiver/googlecloudpubsubreceiver/receiver_test.go index d6862e9bd006..832462cbd5e3 100644 --- a/receiver/googlecloudpubsubreceiver/receiver_test.go +++ b/receiver/googlecloudpubsubreceiver/receiver_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package googlecloudpubsubreceiver import ( diff --git a/receiver/jmxreceiver/internal/subprocess/subprocess.go b/receiver/jmxreceiver/internal/subprocess/subprocess.go index 29eb6395237c..d554cfa961c7 100644 --- a/receiver/jmxreceiver/internal/subprocess/subprocess.go +++ b/receiver/jmxreceiver/internal/subprocess/subprocess.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package subprocess // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/jmxreceiver/internal/subprocess" import ( diff --git a/receiver/k8sclusterreceiver/internal/collection/metricsstore_test.go b/receiver/k8sclusterreceiver/internal/collection/metricsstore_test.go index 8cdb6c02f100..78bddaacdb1e 100644 --- a/receiver/k8sclusterreceiver/internal/collection/metricsstore_test.go +++ b/receiver/k8sclusterreceiver/internal/collection/metricsstore_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package collection import ( diff --git a/receiver/k8sclusterreceiver/receiver_test.go b/receiver/k8sclusterreceiver/receiver_test.go index 5d44ee76dc11..01b4c9c0012f 100644 --- a/receiver/k8sclusterreceiver/receiver_test.go +++ b/receiver/k8sclusterreceiver/receiver_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package k8sclusterreceiver import ( diff --git a/receiver/k8sclusterreceiver/watcher.go b/receiver/k8sclusterreceiver/watcher.go index 6d7cd25599fd..2a1063f7b0cc 100644 --- a/receiver/k8sclusterreceiver/watcher.go +++ b/receiver/k8sclusterreceiver/watcher.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package k8sclusterreceiver // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/k8sclusterreceiver" import ( diff --git a/receiver/k8sclusterreceiver/watcher_test.go b/receiver/k8sclusterreceiver/watcher_test.go index d359f509d1b0..d60a53b34d2b 100644 --- a/receiver/k8sclusterreceiver/watcher_test.go +++ b/receiver/k8sclusterreceiver/watcher_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package k8sclusterreceiver import ( diff --git a/receiver/kafkareceiver/kafka_receiver.go b/receiver/kafkareceiver/kafka_receiver.go index 97eb52305384..f3829eed572d 100644 --- a/receiver/kafkareceiver/kafka_receiver.go +++ b/receiver/kafkareceiver/kafka_receiver.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package kafkareceiver // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/kafkareceiver" import ( diff --git a/receiver/kafkareceiver/kafka_receiver_test.go b/receiver/kafkareceiver/kafka_receiver_test.go index cdb70564e7ec..b81a0e0768cd 100644 --- a/receiver/kafkareceiver/kafka_receiver_test.go +++ b/receiver/kafkareceiver/kafka_receiver_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package kafkareceiver import ( diff --git a/receiver/kubeletstatsreceiver/internal/kubelet/metadata_test.go b/receiver/kubeletstatsreceiver/internal/kubelet/metadata_test.go index 0a195e724ff7..dc2f28783598 100644 --- a/receiver/kubeletstatsreceiver/internal/kubelet/metadata_test.go +++ b/receiver/kubeletstatsreceiver/internal/kubelet/metadata_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package kubelet import ( diff --git a/receiver/mongodbatlasreceiver/internal/mongodb_atlas_client.go b/receiver/mongodbatlasreceiver/internal/mongodb_atlas_client.go index c3b51dc4527f..9afc9ccb390f 100644 --- a/receiver/mongodbatlasreceiver/internal/mongodb_atlas_client.go +++ b/receiver/mongodbatlasreceiver/internal/mongodb_atlas_client.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package internal // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/mongodbatlasreceiver/internal" import ( diff --git a/receiver/mongodbreceiver/scraper_test.go b/receiver/mongodbreceiver/scraper_test.go index de91a59df951..1b5b049d839d 100644 --- a/receiver/mongodbreceiver/scraper_test.go +++ b/receiver/mongodbreceiver/scraper_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package mongodbreceiver import ( diff --git a/receiver/opencensusreceiver/internal/ocmetrics/opencensus_test.go b/receiver/opencensusreceiver/internal/ocmetrics/opencensus_test.go index 3ab2fd9845bc..89cd4c19d048 100644 --- a/receiver/opencensusreceiver/internal/ocmetrics/opencensus_test.go +++ b/receiver/opencensusreceiver/internal/ocmetrics/opencensus_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package ocmetrics import ( diff --git a/receiver/opencensusreceiver/internal/octrace/observability_test.go b/receiver/opencensusreceiver/internal/octrace/observability_test.go index 8a57280885f2..86984e387305 100644 --- a/receiver/opencensusreceiver/internal/octrace/observability_test.go +++ b/receiver/opencensusreceiver/internal/octrace/observability_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package octrace import ( diff --git a/receiver/opencensusreceiver/internal/octrace/opencensus_test.go b/receiver/opencensusreceiver/internal/octrace/opencensus_test.go index d182c6e4b54b..54154404cd49 100644 --- a/receiver/opencensusreceiver/internal/octrace/opencensus_test.go +++ b/receiver/opencensusreceiver/internal/octrace/opencensus_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package octrace import ( diff --git a/receiver/opencensusreceiver/opencensus_test.go b/receiver/opencensusreceiver/opencensus_test.go index b7fa7d4825a1..6d78fe6835f2 100644 --- a/receiver/opencensusreceiver/opencensus_test.go +++ b/receiver/opencensusreceiver/opencensus_test.go @@ -14,6 +14,7 @@ //lint:file-ignore U1000 t.Skip() flaky test causes unused function warning. +// nolint:errcheck package opencensusreceiver import ( diff --git a/receiver/podmanreceiver/receiver_test.go b/receiver/podmanreceiver/receiver_test.go index dece6f8b92d5..7c684a15f393 100644 --- a/receiver/podmanreceiver/receiver_test.go +++ b/receiver/podmanreceiver/receiver_test.go @@ -15,6 +15,7 @@ //go:build !windows // +build !windows +// nolint:errcheck package podmanreceiver import ( diff --git a/receiver/prometheusreceiver/internal/otlp_transaction.go b/receiver/prometheusreceiver/internal/otlp_transaction.go index b4d40efad98b..833f20571540 100644 --- a/receiver/prometheusreceiver/internal/otlp_transaction.go +++ b/receiver/prometheusreceiver/internal/otlp_transaction.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package internal // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/prometheusreceiver/internal" import ( diff --git a/receiver/rabbitmqreceiver/client_test.go b/receiver/rabbitmqreceiver/client_test.go index c3ad435e3844..2d9d8ddf0c81 100644 --- a/receiver/rabbitmqreceiver/client_test.go +++ b/receiver/rabbitmqreceiver/client_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package rabbitmqreceiver // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/rabbitmqreceiver" import ( diff --git a/receiver/rabbitmqreceiver/scraper_test.go b/receiver/rabbitmqreceiver/scraper_test.go index 45a50f68535d..6d250417856b 100644 --- a/receiver/rabbitmqreceiver/scraper_test.go +++ b/receiver/rabbitmqreceiver/scraper_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package rabbitmqreceiver // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/rabbitmqreceiver" import ( diff --git a/receiver/riakreceiver/client_test.go b/receiver/riakreceiver/client_test.go index 239ad4f28926..b906e55dbb5a 100644 --- a/receiver/riakreceiver/client_test.go +++ b/receiver/riakreceiver/client_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package riakreceiver // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/riakreceiver" import ( diff --git a/receiver/saphanareceiver/client.go b/receiver/saphanareceiver/client.go index f9aa99ef92c1..6f4748479def 100644 --- a/receiver/saphanareceiver/client.go +++ b/receiver/saphanareceiver/client.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package saphanareceiver // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/saphanareceiver" import ( diff --git a/receiver/saphanareceiver/queries.go b/receiver/saphanareceiver/queries.go index 76b7d4cdc17a..03a7ad88176f 100644 --- a/receiver/saphanareceiver/queries.go +++ b/receiver/saphanareceiver/queries.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package saphanareceiver // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/saphanareceiver" import ( diff --git a/receiver/sapmreceiver/trace_receiver.go b/receiver/sapmreceiver/trace_receiver.go index 28c4b70b410c..69e2b9d260c6 100644 --- a/receiver/sapmreceiver/trace_receiver.go +++ b/receiver/sapmreceiver/trace_receiver.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package sapmreceiver // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/sapmreceiver" import ( diff --git a/receiver/sapmreceiver/trace_receiver_test.go b/receiver/sapmreceiver/trace_receiver_test.go index 53d87f1661bb..50135dabc490 100644 --- a/receiver/sapmreceiver/trace_receiver_test.go +++ b/receiver/sapmreceiver/trace_receiver_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package sapmreceiver import ( diff --git a/receiver/signalfxreceiver/receiver.go b/receiver/signalfxreceiver/receiver.go index aeedae585bde..730cabee1062 100644 --- a/receiver/signalfxreceiver/receiver.go +++ b/receiver/signalfxreceiver/receiver.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package signalfxreceiver // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/signalfxreceiver" import ( diff --git a/receiver/signalfxreceiver/receiver_test.go b/receiver/signalfxreceiver/receiver_test.go index b71d1878eb45..45f6bbd10ec8 100644 --- a/receiver/signalfxreceiver/receiver_test.go +++ b/receiver/signalfxreceiver/receiver_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package signalfxreceiver import ( diff --git a/receiver/simpleprometheusreceiver/examples/federation/prom-counter/main.go b/receiver/simpleprometheusreceiver/examples/federation/prom-counter/main.go index 3be98af2f291..7b9c131da825 100644 --- a/receiver/simpleprometheusreceiver/examples/federation/prom-counter/main.go +++ b/receiver/simpleprometheusreceiver/examples/federation/prom-counter/main.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package main import ( diff --git a/receiver/splunkhecreceiver/receiver.go b/receiver/splunkhecreceiver/receiver.go index 92d63d82a534..a73415b9a5e9 100644 --- a/receiver/splunkhecreceiver/receiver.go +++ b/receiver/splunkhecreceiver/receiver.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package splunkhecreceiver // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/splunkhecreceiver" import ( diff --git a/receiver/splunkhecreceiver/receiver_test.go b/receiver/splunkhecreceiver/receiver_test.go index aec29b40ec82..1a8ae6a2e3fa 100644 --- a/receiver/splunkhecreceiver/receiver_test.go +++ b/receiver/splunkhecreceiver/receiver_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package splunkhecreceiver import ( diff --git a/receiver/statsdreceiver/protocol/statsd_parser_test.go b/receiver/statsdreceiver/protocol/statsd_parser_test.go index 108b3028cbe4..6927ccf8391b 100644 --- a/receiver/statsdreceiver/protocol/statsd_parser_test.go +++ b/receiver/statsdreceiver/protocol/statsd_parser_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package protocol import ( diff --git a/receiver/statsdreceiver/receiver.go b/receiver/statsdreceiver/receiver.go index d8147579d2e2..0ccf9c260d1d 100644 --- a/receiver/statsdreceiver/receiver.go +++ b/receiver/statsdreceiver/receiver.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package statsdreceiver // import "github.com/open-telemetry/opentelemetry-collector-contrib/receiver/statsdreceiver" import ( diff --git a/receiver/statsdreceiver/receiver_test.go b/receiver/statsdreceiver/receiver_test.go index 898ed5000616..8efbff980786 100644 --- a/receiver/statsdreceiver/receiver_test.go +++ b/receiver/statsdreceiver/receiver_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package statsdreceiver import ( diff --git a/receiver/statsdreceiver/reporter_test.go b/receiver/statsdreceiver/reporter_test.go index 33964201086c..7880a9a0e79f 100644 --- a/receiver/statsdreceiver/reporter_test.go +++ b/receiver/statsdreceiver/reporter_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package statsdreceiver import ( diff --git a/receiver/wavefrontreceiver/receiver_test.go b/receiver/wavefrontreceiver/receiver_test.go index d8b277d86d44..39b215ba9e41 100644 --- a/receiver/wavefrontreceiver/receiver_test.go +++ b/receiver/wavefrontreceiver/receiver_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package wavefrontreceiver import ( diff --git a/receiver/zookeeperreceiver/scraper_test.go b/receiver/zookeeperreceiver/scraper_test.go index 424f5598637f..460eaae778a2 100644 --- a/receiver/zookeeperreceiver/scraper_test.go +++ b/receiver/zookeeperreceiver/scraper_test.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package zookeeperreceiver import ( diff --git a/testbed/datareceivers/mockawsxraydatareceiver.go b/testbed/datareceivers/mockawsxraydatareceiver.go index 41fe3f45aece..99e2cdb6a8e8 100644 --- a/testbed/datareceivers/mockawsxraydatareceiver.go +++ b/testbed/datareceivers/mockawsxraydatareceiver.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package datareceivers // import "github.com/open-telemetry/opentelemetry-collector-contrib/testbed/datareceivers" import ( diff --git a/testbed/mockdatareceivers/mockawsxrayreceiver/trace_receiver.go b/testbed/mockdatareceivers/mockawsxrayreceiver/trace_receiver.go index fd2f265cb95e..8257712ea117 100644 --- a/testbed/mockdatareceivers/mockawsxrayreceiver/trace_receiver.go +++ b/testbed/mockdatareceivers/mockawsxrayreceiver/trace_receiver.go @@ -12,6 +12,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package mockawsxrayreceiver // import "github.com/open-telemetry/opentelemetry-collector-contrib/testbed/mockdatareceivers/mockawsxrayreceiver" import ( diff --git a/tracegen/internal/tracegen/worker.go b/tracegen/internal/tracegen/worker.go index 571454790a61..7787a9babc82 100644 --- a/tracegen/internal/tracegen/worker.go +++ b/tracegen/internal/tracegen/worker.go @@ -13,6 +13,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package tracegen // import "github.com/open-telemetry/opentelemetry-collector-contrib/tracegen/internal/tracegen" import ( diff --git a/tracegen/main.go b/tracegen/main.go index f61d22245146..c6801a89dda8 100644 --- a/tracegen/main.go +++ b/tracegen/main.go @@ -13,6 +13,7 @@ // See the License for the specific language governing permissions and // limitations under the License. +// nolint:errcheck package main import (