Skip to content

Commit

Permalink
Merge branch 'main' into pdata-iterator-all
Browse files Browse the repository at this point in the history
  • Loading branch information
mauri870 committed Feb 14, 2025
2 parents a77c7d1 + 0831231 commit 7c6cfb9
Show file tree
Hide file tree
Showing 153 changed files with 1,099 additions and 581 deletions.
25 changes: 25 additions & 0 deletions .chloggen/deprecate-checkreceivermetrics.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Use this changelog template to create an entry for release notes.

# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
change_type: deprecation

# The name of the component, or a single word describing the area of concern, (e.g. otlpreceiver)
component: component/componenttest

# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Deprecate CheckReceiverMetrics in componenenttest

# One or more tracking issues or pull requests related to the change
issues: [12185]

# (Optional) One or more lines of additional information to render under the primary note.
# These lines will be padded with 2 spaces and then inserted directly into the document.
# Use pipe (|) for multiline entries.
subtext: Use the `metadatatest.AssertEqualMetric` series of functions instead of `obsreporttest.CheckReceiverMetrics`

# Optional: The change log or logs in which this entry should be included.
# e.g. '[user]' or '[user, api]'
# Include 'user' if the change is relevant to end users.
# Include 'api' if there is a change to a library API.
# Default: '[user]'
change_logs: [api]
25 changes: 25 additions & 0 deletions .chloggen/fix-http-receiver.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Use this changelog template to create an entry for release notes.

# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
change_type: bug_fix

# The name of the component, or a single word describing the area of concern, (e.g. otlpreceiver)
component: otlpreceiver

# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Fix OTLP http receiver to correctly set Retry-After

# One or more tracking issues or pull requests related to the change
issues: [12367]

# (Optional) One or more lines of additional information to render under the primary note.
# These lines will be padded with 2 spaces and then inserted directly into the document.
# Use pipe (|) for multiline entries.
subtext:

# Optional: The change log or logs in which this entry should be included.
# e.g. '[user]' or '[user, api]'
# Include 'user' if the change is relevant to end users.
# Include 'api' if there is a change to a library API.
# Default: '[user]'
change_logs: [api, user]
25 changes: 25 additions & 0 deletions .chloggen/generic-makefactorymap.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Use this changelog template to create an entry for release notes.

# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
change_type: 'deprecation'

# The name of the component, or a single word describing the area of concern, (e.g. otlpreceiver)
component: receiver, scraper, processor, exporter, extension

# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Deprecate existing MakeFactoryMap functions in favor of generic implementation

# One or more tracking issues or pull requests related to the change
issues: [12222]

# (Optional) One or more lines of additional information to render under the primary note.
# These lines will be padded with 2 spaces and then inserted directly into the document.
# Use pipe (|) for multiline entries.
subtext:

# Optional: The change log or logs in which this entry should be included.
# e.g. '[user]' or '[user, api]'
# Include 'user' if the change is relevant to end users.
# Include 'api' if there is a change to a library API.
# Default: '[user]'
change_logs: [api]
4 changes: 2 additions & 2 deletions .chloggen/mx-psi_extensiontest-withtype.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@
change_type: deprecation

# The name of the component, or a single word describing the area of concern, (e.g. otlpreceiver)
component: extensiontest
component: extensiontest, connectortest, processortest, receivertest, exportertest, scrapertest

# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Deprecate `extensiontest.NewNopSettings` in favor of `extensiontest.NewNopSettingsWithType`
note: Deprecate `*test.NewNopSettings` in favor of `*test.NewNopSettingsWithType`

# One or more tracking issues or pull requests related to the change
issues: [12305]
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/add-codeowners-to-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
runs-on: ubuntu-24.04
if: ${{ github.actor != 'dependabot[bot]' && github.actor != 'renovate[bot]' && github.repository_owner == 'open-telemetry' }}
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2

- name: Run add-codeowners-to-pr.sh
run: ./.github/workflows/scripts/add-codeowners-to-pr.sh
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/add-labels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ jobs:

runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2

- name: Run add-labels.sh
run: ./.github/workflows/scripts/add-labels.sh
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build-and-test-arm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
arm-unittest-matrix:
strategy:
matrix:
os: [otel-linux-arm64, macos-14]
os: [ubuntu-22.04-arm, macos-14]
if: ${{ github.actor != 'dependabot[bot]' && (contains(github.event.pull_request.labels.*.name, 'Run ARM') || github.event_name == 'push' || github.event_name == 'merge_group') }}
runs-on: ${{ matrix.os }}
steps:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ping-codeowners-issues.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
runs-on: ubuntu-24.04
if: ${{ github.repository_owner == 'open-telemetry' }}
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2

- name: Run ping-codeowners-issues.sh
run: ./.github/workflows/scripts/ping-codeowners-issues.sh
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ping-codeowners-on-new-issue.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
runs-on: ubuntu-24.04
if: ${{ github.repository_owner == 'open-telemetry' }}
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2

- name: Run ping-codeowners-on-new-issue.sh
run: ./.github/workflows/scripts/ping-codeowners-on-new-issue.sh
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ping-codeowners-prs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
runs-on: ubuntu-24.04
if: ${{ github.actor != 'dependabot[bot]' && github.actor != 'renovate[bot]' && github.repository_owner == 'open-telemetry' }}
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2

- name: Run ping-codeowners-prs.sh
run: ./.github/workflows/scripts/ping-codeowners-prs.sh
Expand Down
2 changes: 2 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -270,6 +270,8 @@ check-contrib:
$(addprefix -replace ,$(join $(ALL_MOD_PATHS:%=go.opentelemetry.io/collector%=),$(ALL_MOD_PATHS:%=$(CURDIR)%)))"
@$(MAKE) -j2 -C $(CONTRIB_PATH) gotidy

@$(MAKE) generate-contrib

@echo -e "\nRunning tests"
@$(MAKE) -C $(CONTRIB_PATH) gotest

Expand Down
10 changes: 5 additions & 5 deletions cmd/builder/internal/builder/templates/components.go.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ func components() (otelcol.Factories, error) {
var err error
factories := otelcol.Factories{}

factories.Extensions, err = extension.MakeFactoryMap(
factories.Extensions, err = otelcol.MakeFactoryMap[extension.Factory](
{{- range .Extensions}}
{{.Name}}.NewFactory(),
{{- end}}
Expand All @@ -44,7 +44,7 @@ func components() (otelcol.Factories, error) {
factories.ExtensionModules[{{.Name}}.NewFactory().Type()] = "{{.GoMod}}"
{{- end}}

factories.Receivers, err = receiver.MakeFactoryMap(
factories.Receivers, err = otelcol.MakeFactoryMap[receiver.Factory](
{{- range .Receivers}}
{{.Name}}.NewFactory(),
{{- end}}
Expand All @@ -57,7 +57,7 @@ func components() (otelcol.Factories, error) {
factories.ReceiverModules[{{.Name}}.NewFactory().Type()] = "{{.GoMod}}"
{{- end}}

factories.Exporters, err = exporter.MakeFactoryMap(
factories.Exporters, err = otelcol.MakeFactoryMap[exporter.Factory](
{{- range .Exporters}}
{{.Name}}.NewFactory(),
{{- end}}
Expand All @@ -70,7 +70,7 @@ func components() (otelcol.Factories, error) {
factories.ExporterModules[{{.Name}}.NewFactory().Type()] = "{{.GoMod}}"
{{- end}}

factories.Processors, err = processor.MakeFactoryMap(
factories.Processors, err = otelcol.MakeFactoryMap[processor.Factory](
{{- range .Processors}}
{{.Name}}.NewFactory(),
{{- end}}
Expand All @@ -83,7 +83,7 @@ func components() (otelcol.Factories, error) {
factories.ProcessorModules[{{.Name}}.NewFactory().Type()] = "{{.GoMod}}"
{{- end}}

factories.Connectors, err = connector.MakeFactoryMap(
factories.Connectors, err = otelcol.MakeFactoryMap[connector.Factory](
{{- range .Connectors}}
{{.Name}}.NewFactory(),
{{- end}}
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion cmd/mdatagen/internal/samplereceiver/metrics_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import (

// TestGeneratedMetrics verifies that the internal/metadata API is generated correctly.
func TestGeneratedMetrics(t *testing.T) {
mb := metadata.NewMetricsBuilder(metadata.DefaultMetricsBuilderConfig(), receivertest.NewNopSettings())
mb := metadata.NewMetricsBuilder(metadata.DefaultMetricsBuilderConfig(), receivertest.NewNopSettingsWithType(metadata.Type))
m := mb.Emit()
require.Equal(t, 0, m.ResourceMetrics().Len())
}
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions cmd/mdatagen/internal/status.go
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ func (s *Status) Validate() error {
if err := s.validateClass(); err != nil {
errs = errors.Join(errs, err)
}

if err := s.Stability.Validate(); err != nil {
errs = errors.Join(errs, err)
}
Expand Down
Loading

0 comments on commit 7c6cfb9

Please sign in to comment.