Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[exporter] Continue DataType rename in exporter #11305

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions .chloggen/exportertest-continue-deprecations-2.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: breaking

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

# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Remove deprecated `Settings.DataType`. Use `Settings.Signal` instead.

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

# (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]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

new line. and everywhere.

25 changes: 25 additions & 0 deletions .chloggen/exportertest-continue-deprecations.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: breaking

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

# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Remove deprecated `CheckConsumeContractParams.DataType`. Use `CheckConsumeContractParams.Signal` instead.

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

# (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]
11 changes: 1 addition & 10 deletions exporter/exporterqueue/queue.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ import (
"go.opentelemetry.io/collector/component"
"go.opentelemetry.io/collector/exporter"
"go.opentelemetry.io/collector/exporter/internal/queue"
"go.opentelemetry.io/collector/internal/globalsignal"
"go.opentelemetry.io/collector/pipeline"
)

Expand All @@ -26,10 +25,6 @@ type Queue[T any] queue.Queue[T]

// Settings defines settings for creating a queue.
type Settings struct {

// Deprecated: [v0.110.0] Use Signal instead
DataType component.DataType // nolint

Signal pipeline.Signal
ExporterSettings exporter.Settings
}
Expand Down Expand Up @@ -80,14 +75,10 @@ func NewPersistentQueueFactory[T itemsCounter](storageID *component.ID, factoryS
return NewMemoryQueueFactory[T]()
}
return func(_ context.Context, set Settings, cfg Config) Queue[T] {
signal := set.Signal
if set.DataType.String() != "" {
signal = globalsignal.MustNewSignal(set.DataType.String())
}
return queue.NewPersistentQueue[T](queue.PersistentQueueSettings[T]{
Sizer: sizerFromConfig[T](cfg),
Capacity: capacityFromConfig(cfg),
Signal: signal,
Signal: set.Signal,
StorageID: *storageID,
Marshaler: factorySettings.Marshaler,
Unmarshaler: factorySettings.Unmarshaler,
Expand Down
8 changes: 1 addition & 7 deletions exporter/exportertest/contract_checker.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,7 @@ type uniqueIDAttrVal string
type CheckConsumeContractParams struct {
T *testing.T
NumberOfTestElements int
// DataType to test for.
//
// Deprecated: [v0.110.0] Use Signal instead
// nolint
DataType component.DataType

Signal pipeline.Signal
Signal pipeline.Signal
// ExporterFactory to create an exporter to be tested.
ExporterFactory exporter.Factory
ExporterConfig component.Config
Expand Down
2 changes: 1 addition & 1 deletion exporter/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ require (
go.opentelemetry.io/collector/exporter/exporterprofiles v0.110.0
go.opentelemetry.io/collector/extension v0.110.0
go.opentelemetry.io/collector/extension/experimental/storage v0.110.0
go.opentelemetry.io/collector/internal/globalsignal v0.110.0
go.opentelemetry.io/collector/pdata v1.16.0
go.opentelemetry.io/collector/pdata/pprofile v0.110.0
go.opentelemetry.io/collector/pdata/testdata v0.110.0
Expand Down Expand Up @@ -43,6 +42,7 @@ require (
github.com/pmezard/go-difflib v1.0.0 // indirect
go.opentelemetry.io/collector/component/componentprofiles v0.110.0 // indirect
go.opentelemetry.io/collector/consumer/consumerprofiles v0.110.0 // indirect
go.opentelemetry.io/collector/internal/globalsignal v0.110.0 // indirect
go.opentelemetry.io/collector/receiver/receiverprofiles v0.110.0 // indirect
golang.org/x/net v0.28.0 // indirect
golang.org/x/text v0.17.0 // indirect
Expand Down
Loading