opentelemetry-collector-contrib icon indicating copy to clipboard operation
opentelemetry-collector-contrib copied to clipboard

Enable `gocritic` in missing components

Open mx-psi opened this issue 2 years ago • 2 comments

  • [ ] #12327
  • [x] #11437
  • [x] #10582
  • [x] #10590
  • [ ] Enable gocritic in exporter/datadogexporter
  • [x] #10595
  • [x] #10850
  • [x] #10855
  • [x] #10884
  • [x] #10905
  • [x] #11164
  • [x] #10909
  • [ ] Enable gocritic in exporter/prometheusexporter
  • [ ] Enable gocritic in exporter/prometheusremotewriteexporter
  • [x] #10923
  • [ ] Enable gocritic in exporter/signalfxexporter/internal/translation
  • [x] #11162
  • [ ] Enable gocritic in exporter/splunkhecexporter
  • [x] #11159
  • [x] #11161
  • [x] #11026
  • [x] #11066
  • [x] #11529
  • [ ] Enable gocritic in internal/aws/containerinsight
  • [x] #12328
  • [ ] Enable gocritic in internal/aws/k8s/k8sclient
  • [ ] Enable gocritic in internal/aws/proxy
  • [x] #11156
  • [ ] Enable gocritic in internal/coreinternal/processor/filtermatcher
  • [ ] Enable gocritic in pkg/stanza/adapter
  • [x] #11552
  • [ ] Enable gocritic in processor/k8sattributesprocessor
  • [ ] Enable gocritic in processor/metricstransformprocessor
  • [ ] Enable gocritic in processor/resourcedetectionprocessor/internal/aws/eks
  • [ ] Enable gocritic in processor/routingprocessor
  • [ ] Enable gocritic in processor/spanmetricsprocessor
  • [x] #11778
  • [ ] Enable gocritic in processor/tailsamplingprocessor
  • [ ] Enable gocritic in processor/transformprocessor/internal/logs
  • [ ] Enable gocritic in processor/transformprocessor/internal/metrics
  • [ ] Enable gocritic in processor/transformprocessor/internal/traces
  • [ ] #12325
  • [ ] Enable gocritic in receiver/awsecscontainermetricsreceiver/internal/awsecscontainermetrics
  • [ ] Enable gocritic in receiver/awsxrayreceiver/internal/translator
  • [x] #11793
  • [x] #11421
  • [x] #11794
  • [ ] Enable gocritic in receiver/dotnetdiagnosticsreceiver/metrics
  • [ ] Enable gocritic in receiver/dotnetdiagnosticsreceiver/network
  • [ ] Enable gocritic in receiver/googlecloudpubsubreceiver
  • [x] #12499
  • [ ] Enable gocritic in receiver/googlecloudspannerreceiver/internal/statsreader
  • [ ] Enable gocritic in receiver/hostmetricsreceiver/internal/scraper/cpuscraper
  • [ ] Enable gocritic in receiver/hostmetricsreceiver/internal/scraper/loadscraper
  • [ ] Enable gocritic in receiver/jmxreceiver/internal/subprocess
  • [x] #12214
  • [x] #11798
  • [x] #11799
  • [x] #11806
  • [x] #11802
  • [x] #11804
  • [ ] Enable gocritic in receiver/signalfxreceiver
  • [ ] Enable gocritic in receiver/skywalkingreceiver
  • [ ] Enable gocritic in receiver/splunkhecreceiver
  • [ ] Enable gocritic in receiver/statsdreceiver/protocol
  • [ ] Enable gocritic in receiver/statsdreceiver/transport
  • [x] #11556
  • [ ] Enable gocritic in testbed/datareceivers
  • [x] #11464

List generated by running:

❯ git diff-tree --no-commit-id --name-only -r 0c691295193854523240b609c0c3cc06f9202b41 | rg .go$ | xargs dirname | sort | uniq | awk '{print "- [ ] Enable gocritic in " $0}'

mx-psi avatar May 31 '22 11:05 mx-psi

@mx-psi please assign this to me :)

fatsheep9146 avatar Jun 02 '22 01:06 fatsheep9146

@mx-psi I have checked all component, for gocritic only two components are still not resolved, others can all be checked

  • [x] exporter/datadogexporter: https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/12988
  • [x] receiver/awscontainerinsightreceiver: https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/12325

fatsheep9146 avatar Aug 06 '22 01:08 fatsheep9146

Nice! Looks like pkg/telemetryquerylanguage/contexts/tqlmetrics/metrics.go is also missing, otherwise we are almost finished :)

mx-psi avatar Aug 09 '22 09:08 mx-psi

@mx-psi Can this issue be closed?

evan-bradley avatar Sep 30 '22 17:09 evan-bradley

❯ rg -tgo gocritic -l | cut -d '/' -f 1-2 | sort | uniq
pkg/ottl
receiver/awscontainerinsightreceive

These are the two components missing:

  • The first one has no PR. @TylerHelmuth can you have a look? (Related to pkg/ottl)
  • The second one has an open PR (https://github.com/open-telemetry/opentelemetry-collector-contrib/pull/12325) waiting on a review from @Aneurysm9.

mx-psi avatar Sep 30 '22 17:09 mx-psi

@mx-psi I'll take a look

TylerHelmuth avatar Sep 30 '22 17:09 TylerHelmuth

❯ rg -tgo gocritic -l | cut -d '/' -f 1-2 | sort | uniq
pkg/ottl
receiver/awscontainerinsightreceive

These are the two components missing:

I think this issue is ready to be closed. =D @mx-psi

fatsheep9146 avatar Oct 13 '22 11:10 fatsheep9146

Indeed :tada: :tada: Thanks for your hard work on this @fatsheep9146 !

mx-psi avatar Oct 13 '22 11:10 mx-psi