diff --git a/CHANGELOG.md b/CHANGELOG.md index 6bf79e4b11f..321ef02b651 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -33,7 +33,7 @@ ### 💡 Enhancements 💡 -- Added `MarshalSizer` interface to `ptrace`, `plog`, and `pmetric` packages. `NewProtoMarshaler` now returns a `MarshalSizer` (#5929) +- Added `MarshalerSizer` interface to `ptrace`, `plog`, and `pmetric` packages. `NewProtoMarshaler` now returns a `MarshalerSizer` (#5929) - Add support to unmarshalls bytes into pmetric.Metrics with `jsoniter` in jsonUnmarshaler(#5433) - Add httpprovider to allow loading config files stored in HTTP (#5810) - Added `service.telemetry.traces.propagators` configuration to set propagators for collector's internal spans. (#5572) diff --git a/pdata/plog/encoding.go b/pdata/plog/encoding.go index a03660dd939..69a71c260c4 100644 --- a/pdata/plog/encoding.go +++ b/pdata/plog/encoding.go @@ -14,8 +14,8 @@ package plog // import "go.opentelemetry.io/collector/pdata/plog" -// MarshalSizer is the interface that groups the basic Marshal and Size methods -type MarshalSizer interface { +// MarshalerSizer is the interface that groups the basic Marshal and Size methods +type MarshalerSizer interface { Marshaler Sizer } diff --git a/pdata/plog/pb.go b/pdata/plog/pb.go index babbbee231d..a12c967edcc 100644 --- a/pdata/plog/pb.go +++ b/pdata/plog/pb.go @@ -19,9 +19,9 @@ import ( otlplogs "go.opentelemetry.io/collector/pdata/internal/data/protogen/logs/v1" ) -// NewProtoMarshaler returns a MarshalSizer. +// NewProtoMarshaler returns a MarshalerSizer. // Marshals to OTLP binary protobuf bytes and calculates the size of the marshaled Logs. -func NewProtoMarshaler() MarshalSizer { +func NewProtoMarshaler() MarshalerSizer { return newPbMarshaler() } diff --git a/pdata/pmetric/encoding.go b/pdata/pmetric/encoding.go index 5b9e0327355..51c5acec3a0 100644 --- a/pdata/pmetric/encoding.go +++ b/pdata/pmetric/encoding.go @@ -14,8 +14,8 @@ package pmetric // import "go.opentelemetry.io/collector/pdata/pmetric" -// MarshalSizer is the interface that groups the basic Marshal and Size methods -type MarshalSizer interface { +// MarshalerSizer is the interface that groups the basic Marshal and Size methods +type MarshalerSizer interface { Marshaler Sizer } diff --git a/pdata/pmetric/pb.go b/pdata/pmetric/pb.go index c11f051ad84..db05b35c253 100644 --- a/pdata/pmetric/pb.go +++ b/pdata/pmetric/pb.go @@ -19,9 +19,9 @@ import ( otlpmetrics "go.opentelemetry.io/collector/pdata/internal/data/protogen/metrics/v1" ) -// NewProtoMarshaler returns a MarshalSizer. +// NewProtoMarshaler returns a MarshalerSizer. // Marshals to OTLP binary protobuf bytes and calculates the size of the marshaled Metrics. -func NewProtoMarshaler() MarshalSizer { +func NewProtoMarshaler() MarshalerSizer { return newPbMarshaler() } diff --git a/pdata/ptrace/encoding.go b/pdata/ptrace/encoding.go index 78c2fba7cb8..25fa14e0cdf 100644 --- a/pdata/ptrace/encoding.go +++ b/pdata/ptrace/encoding.go @@ -14,8 +14,8 @@ package ptrace // import "go.opentelemetry.io/collector/pdata/ptrace" -// MarshalSizer is the interface that groups the basic Marshal and Size methods -type MarshalSizer interface { +// MarshalerSizer is the interface that groups the basic Marshal and Size methods +type MarshalerSizer interface { Marshaler Sizer } diff --git a/pdata/ptrace/pb.go b/pdata/ptrace/pb.go index a28e4c29a9e..e164145904a 100644 --- a/pdata/ptrace/pb.go +++ b/pdata/ptrace/pb.go @@ -19,9 +19,9 @@ import ( otlptrace "go.opentelemetry.io/collector/pdata/internal/data/protogen/trace/v1" ) -// NewProtoMarshaler returns a MarshalSizer. +// NewProtoMarshaler returns a MarshalerSizer. // Marshals to OTLP binary protobuf bytes and calculates the size of the marshaled Traces. -func NewProtoMarshaler() MarshalSizer { +func NewProtoMarshaler() MarshalerSizer { return newPbMarshaler() }