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

Remove Min/Max unused interfaces from the moved code #2454

Merged
merged 3 commits into from
Dec 23, 2021
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.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
15 changes: 11 additions & 4 deletions sdk/export/metric/aggregation/aggregation.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
package aggregation // import "go.opentelemetry.io/otel/sdk/export/metric/aggregation"

import (
"go.opentelemetry.io/otel/metric/number"
"go.opentelemetry.io/otel/sdk/metric/export/aggregation"
)

Expand All @@ -27,11 +28,17 @@ type Sum = aggregation.Sum
// Deprecated: use module "go.opentelemetry.io/otel/sdk/metric/export/aggregation"
type Count = aggregation.Count

// Deprecated: use module "go.opentelemetry.io/otel/sdk/metric/export/aggregation"
type Min = aggregation.Min
// Deprecated: Will be removed soon.
type Min interface {
Aggregation
Min() (number.Number, error)
}

// Deprecated: use module "go.opentelemetry.io/otel/sdk/metric/export/aggregation"
type Max = aggregation.Max
// Deprecated: Will be removed soon.
type Max interface {
Aggregation
Max() (number.Number, error)
}
Comment on lines +31 to +41
Copy link
Member Author

Choose a reason for hiding this comment

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

I kept them in the deprecated package, but removed them from the new package since they are not used. They will be removed with the whole deprecated package.


// Deprecated: use module "go.opentelemetry.io/otel/sdk/metric/export/aggregation"
type LastValue = aggregation.LastValue
Expand Down
12 changes: 0 additions & 12 deletions sdk/metric/export/aggregation/aggregation.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,18 +46,6 @@ type (
Count() (uint64, error)
}

// Min returns the minimum value over the set of values that were aggregated.
Min interface {
Aggregation
Min() (number.Number, error)
}

// Max returns the maximum value over the set of values that were aggregated.
Max interface {
Aggregation
Max() (number.Number, error)
}

// LastValue returns the latest value that was aggregated.
LastValue interface {
Aggregation
Expand Down