Skip to content

Commit 0129553

Browse files
authored
Merge branch 'main' into main
2 parents 3289814 + a05740a commit 0129553

File tree

103 files changed

+1261
-471
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

103 files changed

+1261
-471
lines changed
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# Use this changelog template to create an entry for release notes.
2+
3+
# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
4+
change_type: enhancement
5+
6+
# The name of the component, or a single word describing the area of concern, (e.g. filelogreceiver)
7+
component: httpcheckreceiver
8+
9+
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
10+
note: "Added support for specifying multiple endpoints in the `httpcheckreceiver` using the `endpoints` field. Users can now monitor multiple URLs with a single configuration block, improving flexibility and reducing redundancy."
11+
12+
# Mandatory: One or more tracking issues related to the change. You can use the PR number here if no issue exists.
13+
issues: [37121]
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# Use this changelog template to create an entry for release notes.
2+
3+
# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
4+
change_type: enhancement
5+
6+
# The name of the component, or a single word describing the area of concern, (e.g. filelogreceiver)
7+
component: cumulativetodeltaprocessor
8+
9+
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
10+
note: Add metric type filter for cumulativetodelta processor
11+
12+
# Mandatory: One or more tracking issues related to the change. You can use the PR number here if no issue exists.
13+
issues: [33673]
14+
15+
# (Optional) One or more lines of additional information to render under the primary note.
16+
# These lines will be padded with 2 spaces and then inserted directly into the document.
17+
# Use pipe (|) for multiline entries.
18+
subtext:
19+
20+
# If your change doesn't affect end users or the exported elements of any package,
21+
# you should instead start your pull request title with [chore] or use the "Skip Changelog" label.
22+
# Optional: The change log or logs in which this entry should be included.
23+
# e.g. '[user]' or '[user, api]'
24+
# Include 'user' if the change is relevant to end users.
25+
# Include 'api' if there is a change to a library API.
26+
# Default: '[user]'
27+
change_logs: []
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# Use this changelog template to create an entry for release notes.
2+
3+
# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
4+
change_type: enhancement
5+
6+
# The name of the component, or a single word describing the area of concern, (e.g. filelogreceiver)
7+
component: githubgen
8+
9+
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
10+
note: Switch over all usages of githubgen to the new tool location, since the old tool was deprecated
11+
12+
# Mandatory: One or more tracking issues related to the change. You can use the PR number here if no issue exists.
13+
issues: [37412, 37294]
14+
15+
# (Optional) One or more lines of additional information to render under the primary note.
16+
# These lines will be padded with 2 spaces and then inserted directly into the document.
17+
# Use pipe (|) for multiline entries.
18+
subtext:
19+
20+
# If your change doesn't affect end users or the exported elements of any package,
21+
# you should instead start your pull request title with [chore] or use the "Skip Changelog" label.
22+
# Optional: The change log or logs in which this entry should be included.
23+
# e.g. '[user]' or '[user, api]'
24+
# Include 'user' if the change is relevant to end users.
25+
# Include 'api' if there is a change to a library API.
26+
# Default: '[user]'
27+
change_logs: []
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
change_type: enhancement
2+
3+
component: googlecloudpubsubreceiver
4+
5+
note: Added support for encoding extensions.
6+
7+
issues: [37109]
8+
9+
subtext:
10+
11+
change_logs: [user]

.github/ALLOWLIST

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,11 @@
11
# Code generated by githubgen. DO NOT EDIT.
22
#####################################################
33
#
4-
# List of components in OpenTelemetry Collector Contrib
4+
# List of components
55
# waiting on owners to be assigned
66
#
77
#####################################################
88
#
9-
# Learn about membership in OpenTelemetry community:
10-
# https://github.com/open-telemetry/community/blob/main/guides/contributor/membership.md
11-
#
12-
#
139
# Learn about CODEOWNERS file format:
1410
# https://help.github.com/en/articles/about-code-owners
1511
#

.github/CODEOWNERS

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,10 @@
11
# Code generated by githubgen. DO NOT EDIT.
22
#####################################################
33
#
4-
# List of codeowners for OpenTelemetry Collector Contrib
4+
# List of codeowners
55
#
66
#####################################################
77
#
8-
# Learn about membership in OpenTelemetry community:
9-
# https://github.com/open-telemetry/community/blob/main/guides/contributor/membership.md
10-
#
11-
#
128
# Learn about CODEOWNERS file format:
139
# https://help.github.com/en/articles/about-code-owners
1410
#
@@ -317,16 +313,18 @@ testbed/mockdatasenders/mockdatadogagentexporter/ @open-telemetry
317313

318314
#####################################################
319315
#
320-
# List of distribution maintainers for OpenTelemetry Collector Contrib
316+
# List of distribution maintainers
321317
#
322318
#####################################################
323319

324320
reports/distributions/core.yaml @open-telemetry/collector-contrib-approvers
325321
reports/distributions/contrib.yaml @open-telemetry/collector-contrib-approvers
326322
reports/distributions/k8s.yaml @open-telemetry/collector-contrib-approvers
327-
323+
#####################################################
324+
#
328325
## UNMAINTAINED components
329-
326+
#
327+
#####################################################
330328
exporter/kineticaexporter/ @open-telemetry/collector-contrib-approvers
331329
exporter/opensearchexporter/ @open-telemetry/collector-contrib-approvers
332330
extension/observer/ecstaskobserver/ @open-telemetry/collector-contrib-approvers

.github/workflows/check-codeowners.yaml

Lines changed: 13 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -21,42 +21,40 @@ concurrency:
2121
cancel-in-progress: true
2222

2323
jobs:
24-
setup-environment:
24+
check-codeowners:
2525
timeout-minutes: 30
2626
runs-on: ubuntu-24.04
2727
if: ${{ github.actor != 'dependabot[bot]' && github.repository == 'open-telemetry/opentelemetry-collector-contrib' }}
2828
steps:
2929
- uses: actions/checkout@v4
30+
3031
- uses: actions/setup-go@v5
3132
with:
3233
go-version: "1.22.8"
3334
cache: false
34-
- name: Cache Go
35-
id: go-cache
35+
36+
- name: Cache Go Tools
37+
id: go-tools-cache
3638
timeout-minutes: 5
3739
uses: actions/cache@v4
3840
with:
3941
path: |
40-
~/go/bin
41-
~/go/pkg/mod
4242
./.tools
43-
key: go-cache-${{ runner.os }}-${{ hashFiles('**/go.sum') }}
44-
check-codeowners:
45-
runs-on: ubuntu-24.04
46-
needs: [setup-environment]
47-
steps:
48-
- uses: actions/checkout@v4
49-
- name: Gen githubgen tool
43+
key: go-tools-${{ runner.os }}-${{ hashFiles('internal/tools/go.sum') }}
44+
45+
- name: Install tools
46+
if: github.repository == 'open-telemetry/opentelemetry-collector-contrib' && steps.go-tools-cache.outputs.cache-hit != 'true'
5047
run: |
51-
make githubgen-install
52-
echo "$(go env GOPATH)/bin" >> $GITHUB_PATH
48+
make install-tools
49+
5350
- uses: actions/checkout@v4
5451
with:
5552
ref: ${{github.event.pull_request.head.ref}}
5653
repository: ${{github.event.pull_request.head.repo.full_name}}
5754
path: pr
55+
5856
- name: Gen CODEOWNERS
5957
run: |
6058
cd pr
61-
GITHUB_TOKEN=${{ secrets.READ_ORG_AND_USER_TOKEN }} githubgen
59+
GITHUB_TOKEN=${{ secrets.READ_ORG_AND_USER_TOKEN }} ../.tools/githubgen codeowners
6260
git diff -s --exit-code || (echo 'Generated code is out of date, please apply this diff and commit the changes in this PR.' && git diff && exit 1)

.golangci.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,9 @@ linters-settings:
166166
explicit-exhaustive-switch: true
167167
ignore-enum-members: "pmetric.MetricTypeEmpty"
168168

169+
nolintlint:
170+
require-specific: true
171+
169172
predeclared:
170173
ignore: copy
171174

@@ -201,6 +204,7 @@ linters:
201204
- gosec
202205
- govet
203206
- misspell
207+
- nolintlint
204208
- predeclared
205209
- reassign
206210
- revive
@@ -227,3 +231,7 @@ issues:
227231
- text: "G115:"
228232
linters:
229233
- gosec
234+
- path: "pagefile.go" # This exclusion is required for Windows only
235+
text: "cachedBytes"
236+
linters:
237+
- unused

CONTRIBUTING.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -215,6 +215,7 @@ When submitting a component to the community, consider breaking it down into sep
215215
* `make generate`
216216
* `make multimod-verify`
217217
* `make generate-gh-issue-templates`
218+
* `make gengithub`
218219
* `make addlicense`
219220
* **Second PR** should include the concrete implementation of the component. If the
220221
size of this PR is larger than the recommended size consider splitting it in

Makefile

Lines changed: 8 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -310,20 +310,16 @@ generate: install-tools
310310
PATH="$$PWD/.tools:$$PATH" $(MAKE) for-all CMD="$(GOCMD) generate ./..."
311311
$(MAKE) gofmt
312312

313-
.PHONY: githubgen-install
314-
githubgen-install:
315-
cd cmd/githubgen && $(GOCMD) install .
316-
317313
.PHONY: gengithub
318-
gengithub: githubgen-install
319-
githubgen
314+
gengithub: $(GITHUBGEN)
315+
$(GITHUBGEN)
320316

321317
.PHONY: gendistributions
322-
gendistributions: githubgen-install
323-
githubgen distributions
318+
gendistributions: $(GITHUBGEN)
319+
$(GITHUBGEN) distributions
324320

325321
.PHONY: update-codeowners
326-
update-codeowners: gengithub generate
322+
update-codeowners: generate gengithub
327323

328324
FILENAME?=$(shell git branch --show-current)
329325
.PHONY: chlog-new
@@ -344,7 +340,7 @@ chlog-update: $(CHLOGGEN)
344340

345341
.PHONY: genotelcontribcol
346342
genotelcontribcol: $(BUILDER)
347-
$(BUILDER) --skip-compilation --config cmd/otelcontribcol/builder-config.yaml --output-path cmd/otelcontribcol
343+
$(BUILDER) --skip-compilation --config cmd/otelcontribcol/builder-config.yaml
348344

349345
# Build the Collector executable.
350346
.PHONY: otelcontribcol
@@ -360,7 +356,7 @@ otelcontribcollite: genotelcontribcol
360356

361357
.PHONY: genoteltestbedcol
362358
genoteltestbedcol: $(BUILDER)
363-
$(BUILDER) --skip-compilation --config cmd/oteltestbedcol/builder-config.yaml --output-path cmd/oteltestbedcol
359+
$(BUILDER) --skip-compilation --config cmd/oteltestbedcol/builder-config.yaml
364360

365361
# Build the Collector executable, with only components used in testbed.
366362
.PHONY: oteltestbedcol
@@ -559,8 +555,7 @@ clean:
559555

560556
.PHONY: generate-gh-issue-templates
561557
generate-gh-issue-templates:
562-
cd cmd/githubgen && $(GOCMD) install .
563-
githubgen issue-templates
558+
$(GITHUBGEN) issue-templates
564559

565560
.PHONY: checks
566561
checks:

Makefile.Common

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@ MISSPELL_CORRECTION := $(TOOLS_BIN_DIR)/misspell -w
6868
LINT := $(TOOLS_BIN_DIR)/golangci-lint
6969
MULTIMOD := $(TOOLS_BIN_DIR)/multimod
7070
CHLOGGEN := $(TOOLS_BIN_DIR)/chloggen
71+
GITHUBGEN := $(TOOLS_BIN_DIR)/githubgen
7172
GOIMPORTS := $(TOOLS_BIN_DIR)/goimports
7273
PORTO := $(TOOLS_BIN_DIR)/porto
7374
CHECKFILE := $(TOOLS_BIN_DIR)/checkfile

cmd/githubgen/allowlist.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ abhishek-at-cloudwerx
22
adcharre
33
Caleb-Hurshman
44
cemdk
5-
cheempz
65
dlopes7
76
driverpt
87
dsimil

cmd/githubgen/metadata.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
type: githubgen
22

33
status:
4+
stability:
5+
deprecated: []
46
class: cmd
57
codeowners:
6-
active: [atoulme]
8+
active: [atoulme]

cmd/otelcontribcol/builder-config.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ dist:
1111
name: otelcontribcol
1212
description: Local OpenTelemetry Collector Contrib binary, testing only.
1313
version: 0.118.0-dev
14+
output_path: ./cmd/otelcontribcol
1415

1516
extensions:
1617
- gomod: go.opentelemetry.io/collector/extension/zpagesextension v0.118.1-0.20250121185328-fbefb22cc2b3

cmd/oteltestbedcol/builder-config.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ dist:
88
name: oteltestbedcol
99
description: OpenTelemetry Collector binary for testbed only tests.
1010
version: 0.118.0-dev
11+
output_path: ./cmd/oteltestbedcol
1112

1213
extensions:
1314
- gomod: go.opentelemetry.io/collector/extension/zpagesextension v0.118.1-0.20250121185328-fbefb22cc2b3

cmd/telemetrygen/internal/logs/worker.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,13 +58,11 @@ func (w worker) simulateLogs(res *resource.Resource, exporterFunc func() (sdklog
5858

5959
if w.spanID != "" {
6060
// we checked this for errors in the Validate function
61-
// nolint: errcheck
6261
b, _ := hex.DecodeString(w.spanID)
6362
sid = trace.SpanID(b)
6463
}
6564
if w.traceID != "" {
6665
// we checked this for errors in the Validate function
67-
// nolint: errcheck
6866
b, _ := hex.DecodeString(w.traceID)
6967
tid = trace.TraceID(b)
7068
}

cmd/telemetrygen/internal/metrics/metrics.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -128,14 +128,12 @@ func exemplarsFromConfig(c *Config) []metricdata.Exemplar[int64] {
128128

129129
if c.TraceID != "" {
130130
// we validated this already during the Validate() function for config
131-
// nolint: errcheck
132131
traceID, _ := hex.DecodeString(c.TraceID)
133132
exemplar.TraceID = traceID
134133
}
135134

136135
if c.SpanID != "" {
137136
// we validated this already during the Validate() function for config
138-
// nolint: errcheck
139137
spanID, _ := hex.DecodeString(c.SpanID)
140138
exemplar.SpanID = spanID
141139
}

connector/datadogconnector/example_test.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,6 @@ func TestExamples(t *testing.T) {
2525
t.Setenv("DD_API_KEY", "aaaaaaaaa")
2626
factories := newTestComponents(t)
2727
const configFile = "./examples/config.yaml"
28-
// https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/33594
29-
// nolint:staticcheck
3028
_, err := otelcoltest.LoadConfigAndValidate(configFile, factories)
3129
require.NoError(t, err, "All yaml config must validate. Please ensure that all necessary component factories are added in newTestComponents()")
3230
}

connector/servicegraphconnector/config_test.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,6 @@ func TestLoadConfig(t *testing.T) {
2222
require.NoError(t, err)
2323

2424
factories.Connectors[metadata.Type] = NewFactory()
25-
// https://github.com/open-telemetry/opentelemetry-collector-contrib/issues/33594
26-
// nolint:staticcheck
2725
cfg, err := otelcoltest.LoadConfigAndValidate(filepath.Join("testdata", "service-graph-connector-config.yaml"), factories)
2826

2927
// Verify

connector/servicegraphconnector/internal/store/store.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ func (s *Store) Expire() {
110110
defer s.mtx.Unlock()
111111

112112
// Iterates until no more items can be evicted
113-
for s.tryEvictHead() { // nolint
113+
for s.tryEvictHead() {
114114
}
115115
}
116116

exporter/awskinesisexporter/internal/batch/batch.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import (
77
"errors"
88

99
"github.com/aws/aws-sdk-go-v2/aws"
10-
"github.com/aws/aws-sdk-go-v2/service/kinesis/types" //nolint:staticcheck // Some encoding types uses legacy prototype version
10+
"github.com/aws/aws-sdk-go-v2/service/kinesis/types"
1111
"go.opentelemetry.io/collector/consumer/consumererror"
1212

1313
"github.com/open-telemetry/opentelemetry-collector-contrib/exporter/awskinesisexporter/internal/compress"

0 commit comments

Comments
 (0)