Skip to content

Commit

Permalink
Merge branch 'main' into metrics-sizer2
Browse files Browse the repository at this point in the history
  • Loading branch information
iblancasa authored Mar 5, 2025
2 parents fbb1ef4 + e43c36c commit 180478c
Show file tree
Hide file tree
Showing 156 changed files with 1,267 additions and 785 deletions.
25 changes: 25 additions & 0 deletions .chloggen/mdatagen_deprecation_fields.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: enhancement

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

# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Add deprecation date and migration guide fields as part of component metadata

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

# (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: []
25 changes: 25 additions & 0 deletions .chloggen/mx-psi_split-the-helpers.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: new_component

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

# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Split `receiverhelper` into a separate module

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

# (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]
33 changes: 33 additions & 0 deletions .chloggen/telemetry-level-update.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# Use this changelog template to create an entry for release notes.

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

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

# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Batch processor telemetry is no longer emitted at "basic" verbosity level

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

# (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: |
According to the guidelines, basic-level telemetry should be reserved for core Collector APIs.
Components such as the batch processor should emit telemetry starting from the "normal" level
(which is also the default level).
Migration: If your Collector telemetry was set to `level: basic` and you want to keep seeing
batch processor-related metrics, consider switching to `level: normal` instead.
# 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: [user]
8 changes: 4 additions & 4 deletions client/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@ require (
github.com/modern-go/reflect2 v1.0.2 // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
go.uber.org/multierr v1.11.0 // indirect
golang.org/x/net v0.33.0 // indirect
golang.org/x/sys v0.28.0 // indirect
golang.org/x/net v0.34.0 // indirect
golang.org/x/sys v0.29.0 // indirect
golang.org/x/text v0.21.0 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20241202173237-19429a94021a // indirect
google.golang.org/grpc v1.70.0 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20250115164207-1a7da9e5054f // indirect
google.golang.org/grpc v1.71.0 // indirect
google.golang.org/protobuf v1.36.5 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
)
Expand Down
38 changes: 20 additions & 18 deletions client/go.sum

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

1 change: 1 addition & 0 deletions cmd/builder/internal/builder/main_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ var replaceModules = []string{
"/receiver/nopreceiver",
"/receiver/otlpreceiver",
"/receiver/receivertest",
"/receiver/receiverhelper",
"/receiver/xreceiver",
"/semconv",
"/service",
Expand Down
6 changes: 3 additions & 3 deletions cmd/mdatagen/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -61,10 +61,10 @@ require (
go.opentelemetry.io/otel v1.34.0 // indirect
go.opentelemetry.io/otel/sdk v1.34.0 // indirect
go.uber.org/multierr v1.11.0 // indirect
golang.org/x/net v0.33.0 // indirect
golang.org/x/net v0.34.0 // indirect
golang.org/x/sys v0.29.0 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20241202173237-19429a94021a // indirect
google.golang.org/grpc v1.70.0 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20250115164207-1a7da9e5054f // indirect
google.golang.org/grpc v1.71.0 // indirect
google.golang.org/protobuf v1.36.5 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
)
Expand Down
12 changes: 6 additions & 6 deletions cmd/mdatagen/go.sum

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

25 changes: 25 additions & 0 deletions cmd/mdatagen/internal/command_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -299,6 +299,7 @@ func TestInlineReplace(t *testing.T) {
componentClass string
warnings []string
stability map[component.StabilityLevel][]string
deprecation map[string]DeprecationInfo
distros []string
codeowners *Codeowners
githubProject string
Expand Down Expand Up @@ -462,6 +463,29 @@ Some info about a component
},
distros: []string{"contrib"},
},
{
name: "readme with multiple signals and deprecation",
markdown: `# Some component
<!-- status autogenerated section -->
<!-- end autogenerated section -->
Some info about a component
`,
outputFile: "readme_with_multiple_signals_and_deprecation.md",
stability: map[component.StabilityLevel][]string{
component.StabilityLevelBeta: {"metrics"},
component.StabilityLevelAlpha: {"logs"},
component.StabilityLevelDeprecated: {"traces"},
},
deprecation: DeprecationMap{
"traces": DeprecationInfo{
Date: "2025-02-05",
Migration: "no migration needed",
},
},
distros: []string{"contrib"},
},
{
name: "readme with cmd class",
markdown: `# Some component
Expand Down Expand Up @@ -496,6 +520,7 @@ Some info about a component
Class: tt.componentClass,
Warnings: tt.warnings,
Codeowners: tt.codeowners,
Deprecation: tt.deprecation,
},
}
tmpdir := t.TempDir()
Expand Down
7 changes: 7 additions & 0 deletions cmd/mdatagen/internal/loader_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,15 @@ func TestLoadMetadata(t *testing.T) {
component.StabilityLevelDevelopment: {"logs"},
component.StabilityLevelBeta: {"traces"},
component.StabilityLevelStable: {"metrics"},
component.StabilityLevelDeprecated: {"profiles"},
},
Distributions: []string{},
Deprecation: DeprecationMap{
"profiles": DeprecationInfo{
Date: "2025-02-05",
Migration: "no migration needed",
},
},
Codeowners: &Codeowners{
Active: []string{"dmitryax"},
},
Expand Down
16 changes: 16 additions & 0 deletions cmd/mdatagen/internal/metadata_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,22 @@ func TestValidate(t *testing.T) {
name: "testdata/no_stability.yaml",
wantErr: "missing stability",
},
{
name: "testdata/no_deprecation_info.yaml",
wantErr: "deprecated component missing deprecation date and migration guide for traces",
},
{
name: "testdata/no_deprecation_date_info.yaml",
wantErr: "deprecated component missing date in YYYY-MM-DD format: traces",
},
{
name: "testdata/no_deprecation_migration_info.yaml",
wantErr: "deprecated component missing migration guide: traces",
},
{
name: "testdata/deprecation_info_invalid_date.yaml",
wantErr: "deprecated component missing valid date in YYYY-MM-DD format: traces",
},
{
name: "testdata/invalid_stability.yaml",
wantErr: "decoding failed due to the following error(s):\n\nerror decoding 'status.stability': unsupported stability level: \"incorrectstability\"",
Expand Down
8 changes: 7 additions & 1 deletion cmd/mdatagen/internal/samplereceiver/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,24 @@ This receiver is used for testing purposes to check the output of mdatagen.
<!-- status autogenerated section -->
| Status | |
| ------------- |-----------|
| Stability | [development]: logs |
| Stability | [deprecated]: profiles |
| | [development]: logs |
| | [beta]: traces |
| | [stable]: metrics |
| Deprecation of profiles | [Date]: 2025-02-05 |
| | [Migration Note]: no migration needed |
| Unsupported Platforms | freebsd, illumos |
| Distributions | [] |
| Warnings | [Any additional information that should be brought to the consumer's attention](#warnings) |
| Issues | [![Open issues](https://img.shields.io/github/issues-search/open-telemetry/opentelemetry-collector?query=is%3Aissue%20is%3Aopen%20label%3Areceiver%2Fsample%20&label=open&color=orange&logo=opentelemetry)](https://github.com/open-telemetry/opentelemetry-collector/issues?q=is%3Aopen+is%3Aissue+label%3Areceiver%2Fsample) [![Closed issues](https://img.shields.io/github/issues-search/open-telemetry/opentelemetry-collector?query=is%3Aissue%20is%3Aclosed%20label%3Areceiver%2Fsample%20&label=closed&color=blue&logo=opentelemetry)](https://github.com/open-telemetry/opentelemetry-collector/issues?q=is%3Aclosed+is%3Aissue+label%3Areceiver%2Fsample) |
| [Code Owners](https://github.com/open-telemetry/opentelemetry-collector-contrib/blob/main/CONTRIBUTING.md#becoming-a-code-owner) | [@dmitryax](https://www.github.com/dmitryax) |

[deprecated]: https://github.com/open-telemetry/opentelemetry-collector/blob/main/docs/component-stability.md#deprecated
[development]: https://github.com/open-telemetry/opentelemetry-collector/blob/main/docs/component-stability.md#development
[beta]: https://github.com/open-telemetry/opentelemetry-collector/blob/main/docs/component-stability.md#beta
[stable]: https://github.com/open-telemetry/opentelemetry-collector/blob/main/docs/component-stability.md#stable
[Date]: https://github.com/open-telemetry/opentelemetry-collector/blob/main/docs/component-stability.md#deprecation-information
[Migration Note]: https://github.com/open-telemetry/opentelemetry-collector/blob/main/docs/component-stability.md#deprecation-information
<!-- end autogenerated section -->

## Warnings
Expand Down

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

5 changes: 5 additions & 0 deletions cmd/mdatagen/internal/samplereceiver/metadata.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,11 @@ status:
development: [logs]
beta: [traces]
stable: [metrics]
deprecated: [profiles]
deprecation:
profiles:
migration: "no migration needed"
date: "2025-02-05"
distributions: []
unsupported_platforms: [freebsd, illumos]
codeowners:
Expand Down
Loading

0 comments on commit 180478c

Please sign in to comment.