-
Notifications
You must be signed in to change notification settings - Fork 452
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
Should Exporter force async? #2031
Comments
I'm coming from #2071. My opinion is that If performance is a concern then multiple methods are a good approach I think. |
I ran the benchmarks myself to compare, and I agree that there's an overhead when using the
However I also added an impl using native async trait support now that Rust supports it for a while:
This suggests that there is no real overhead when using native async traits. This means that there may be no need to require multiple methods if async is good enough. |
@demurgos can you send a PR to modify the benchmark to use the native async trait part? |
@cijothomas Here you go: #2143 |
Exporter traits are now written as async. This works great if the exporter actually needs to use async. But when exporter is not needing async (like when exporting to kernel tracing systems like Windows ETW, Linux user_events), the async is causing unnecessary overhead, as shown in the benchmarks.
This issue is to track addressing this. One way could be offer multiple methods. Another would be model etw/user-events exporter as a processor itself,
The text was updated successfully, but these errors were encountered: