-
Notifications
You must be signed in to change notification settings - Fork 462
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
[Nginx] Add benchmark template for error logs #8777
Conversation
This is a benchmark template for nginx error logs. It is not complete yet but I share it early to discuss someo of the challenges.
"message": "{{$timestamp | date "2006/01/02 15:04:05"}} [error] {{$processPid}}#{{$processThreadId}}: *1 open() \"/usr/local/Cellar/nginx/1.10.2_1/html/favicon.ico\" failed (2: No such file or directory), client: {{$ip}}, server: localhost, request: \"GET /favicon.ico HTTP/1.1\", host: \"localhost:8080\", referrer: \"http://localhost:8080/\"", | ||
"event": { | ||
"dataset": "nginx.error", | ||
"timezone": "CET" |
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.
I'm using this to get the right timezone. But this should be dynamic to where the data is generated from to make sure it is always accurate.
My initial plan was to use timestamp.Zone
and use the first return param but turns out it is not possible in templates to use functions with more then one return param.
@aspacca As this is a common problem, it would be nice if for example timezone
as variable would always be available? What other solutions are there?
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.
you can use $timestamp.Format "MST"
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.
@aliabbas-elastic Could you try this out in your PR?
🚀 Benchmarks reportTo see the full report comment with |
/test benchmark fullreport |
Hi @ruflin, please update your branch with the latest contents from main branch. There was an important PR merged updating the CI pipelines. Thanks! |
Closing as all the changes went into #8762 |
This is a benchmark template for nginx error logs. It is not complete yet but I share it early to discuss someo of the challenges.