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

Current spans map: consider using RemoteAddr field #2

Closed
mariomac opened this issue Feb 20, 2023 · 1 comment
Closed

Current spans map: consider using RemoteAddr field #2

mariomac opened this issue Feb 20, 2023 · 1 comment

Comments

@mariomac
Copy link
Contributor

During the aggregation of HTTP call spans, the eBPF code stores ongoing spans by using the request context pointer as key (private field ctx in type http.Request).

While this is performant (only have to store a pointer as map key), this is an implementation detail that might be broken if the http.Request implementation changes.

We could consider using something more stable, such as the public field http.Request.RemoteAddr. However this might involve some extra processing because this field is a variable-length string.

@mariomac
Copy link
Contributor Author

mariomac commented May 4, 2023

There is something similar already done. Closing by now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant