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

Investigate improvements to httprequest parsing for logs #699

Open
dashpole opened this issue Aug 8, 2023 · 0 comments
Open

Investigate improvements to httprequest parsing for logs #699

dashpole opened this issue Aug 8, 2023 · 0 comments
Labels
enhancement accepted An actionable enhancement for which PRs will be accepted enhancement New feature or request priority: p3

Comments

@dashpole
Copy link
Contributor

dashpole commented Aug 8, 2023

Follow-up to #697

In

func (l logMapper) parseHTTPRequest(httpRequestAttr pcommon.Value) (*logtypepb.HttpRequest, error) {
, we translate the http attribute to the structured fields in the LogRecord.

We might be able to directly unmarshal into https://pkg.go.dev/google.golang.org/genproto/googleapis/logging/type#HttpRequest, as that has the same tags. I wasn't able to get that to work in my experimentation, as I think it used the tags with underscores, rather than the camelCase tag name.

If it is a map, we might be able to go directly from the map to attributes without the conversion to a json string in-between.

@dashpole dashpole added enhancement New feature or request priority: p3 enhancement accepted An actionable enhancement for which PRs will be accepted labels Aug 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement accepted An actionable enhancement for which PRs will be accepted enhancement New feature or request priority: p3
Projects
None yet
Development

No branches or pull requests

1 participant