Skip to content

Support bytes_value type for LogRecord Body #3487

Closed
@mithunbelur

Description

@mithunbelur

I see that Log Record body cannot take in bytes_value.

void OtlpLogRecordable::SetBody(const opentelemetry::common::AttributeValue &message) noexcept
{
OtlpPopulateAttributeUtils::PopulateAnyValue(proto_record_.mutable_body(), message);
}

I see that OtlpPopulateAttributeUtils::PopulateAnyValue doesn't call set_bytes_value for any data type.
But, the otlp proto has this option.

Is your feature request related to a problem?
I was planning to send another protobuf as log body in Otel Resource Logs. I tried from golang client and it's working. But wanted the same in cpp.

Describe the solution you'd like
I would like to have the same behaviour from cpp clients as well.

Describe alternatives you've considered
Trying to enhance the server side to accept array_value as cpp clients can send array_value.

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingtriage/acceptedIndicates an issue or PR is ready to be actively worked on.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions