-
Notifications
You must be signed in to change notification settings - Fork 304
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
[Exporter.Geneva] Adding user_events support for logs on Linux - user_events data transport utility #2479
base: main
Are you sure you want to change the base?
[Exporter.Geneva] Adding user_events support for logs on Linux - user_events data transport utility #2479
Conversation
…ser_events tests for logs and traces as well.
…ort user_events yet.
Disable the test case for now. The kernel in test runner doesn't support user_events yet. Error message:
There is an issue tracking this: #2326. |
|
||
eb.AddString16("severityText", "Critical"); | ||
eb.AddString16("name", "CheckoutFailed"); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
eventid and event name too?
EnsureUserEventsEnabled(); | ||
|
||
var listener = new PerfTracepointListener( | ||
"MicrosoftOpenTelemetryLogs_L4K1", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is "L4" hardcoded? or its based on severity?
Also, is K1 fixed with no ability to change?
Towards #2474
Changes
Add a
UnixUserEventsDataTransport
utility class which will be used for sending user_events data.Testing
Prerequisites
Steps
To capture the user_events, the perf tool has to be run while
dotnet test
is running. The most simple way is to do in two terminals.Terminal 1
Run the tests:
Terminal 2
Check if events are ready with this command:
sudo ls /sys/kernel/tracing/events/user_events/
.When the dotnet test outputs reached
------------- ready to write events -------------
, the test would wait for 5 seconds before actually sending user_events. You can see events are ready by running the first command:Before the tests send out user_events in 5 seconds, run the perf tool:
sudo ./perf record -v -e user_events:MicrosoftOpenTelemetryLogs_L4K1
.Once the dotnet test command finishes, ctrl-c to terminate the capture.
Run
sudo /mnt/c/repos/LinuxTracepoints/bin/perf-decode ./perf.data
to decode the user_events data:Formatted:
Merge requirement checklist
[ ] Appropriate: will add when the feature is readyCHANGELOG.md
files updated for non-trivial changes[ ] Changes in public API reviewed (if applicable)