-
Notifications
You must be signed in to change notification settings - Fork 8.2k
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
[APM UI] Fix Latency distribution chart breaks due to transaction durations of value 0 #191994
[APM UI] Fix Latency distribution chart breaks due to transaction durations of value 0 #191994
Conversation
🤖 GitHub commentsExpand to view the GitHub comments
Just comment with:
|
597ddc3
to
8180339
Compare
...lity_solution/apm/server/routes/correlations/queries/fetch_duration_histogram_range_steps.ts
Outdated
Show resolved
Hide resolved
dc527be
to
f9b3a90
Compare
Pinging @elastic/obs-ux-infra_services-team (Team:obs-ux-infra_services) |
/ci |
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.
LGTM 🚀
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.
Code LGTM! 🚀
...lity_solution/apm/server/routes/correlations/queries/fetch_duration_histogram_range_steps.ts
Outdated
Show resolved
Hide resolved
20c073d
to
a071a1b
Compare
a071a1b
to
a62c25d
Compare
💚 Build Succeeded
Metrics [docs]
History
To update your PR or re-run it, just comment with: |
…ations of value 0 (elastic#191994) ## Summary Fixes: elastic#184256 This PR fixes the APM latency distribution chart not being able to render when we had any duration value as 0, to fix it, we now check if it's 0 and override it with 1. |Before|After| |-|-| |![image](https://github.com/user-attachments/assets/df224a1d-a669-4ea8-ad0e-9f81a82b904a)|![image](https://github.com/user-attachments/assets/cbf6957c-df6f-4f71-8f96-7985279912fa)| ## Test steps 1. Open the following file `x-pack/plugins/observability_solution/apm/server/routes/correlations/queries/fetch_duration_histogram_range_steps.ts` 2. Modify L61 and L118 changing the initial two values passed to `getHistogramRangeSteps` to 0. Like `getHistogramRangeSteps(0, 0, steps)`. It doesn't matter the order, if one of the params is at 0 it won't render anything. 3. Revert the change and check if the chart is being rendered. (cherry picked from commit 917473f)
💚 All backports created successfully
Note: Successful backport PRs will be merged automatically after passing CI. Questions ?Please refer to the Backport tool documentation |
…ion durations of value 0 (#191994) (#192165) # Backport This will backport the following commits from `main` to `8.15`: - [[APM UI] Fix Latency distribution chart breaks due to transaction durations of value 0 (#191994)](#191994) <!--- Backport version: 9.4.3 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Sergi Romeu","email":"sergi.romeu@elastic.co"},"sourceCommit":{"committedDate":"2024-09-05T10:35:29Z","message":"[APM UI] Fix Latency distribution chart breaks due to transaction durations of value 0 (#191994)\n\n## Summary\r\nFixes: https://github.com/elastic/kibana/issues/184256\r\n\r\nThis PR fixes the APM latency distribution chart not being able to\r\nrender when we had any duration value as 0, to fix it, we now check if\r\nit's 0 and override it with 1.\r\n\r\n|Before|After|\r\n|-|-|\r\n\r\n|![image](https://github.com/user-attachments/assets/df224a1d-a669-4ea8-ad0e-9f81a82b904a)|![image](https://github.com/user-attachments/assets/cbf6957c-df6f-4f71-8f96-7985279912fa)|\r\n\r\n## Test steps\r\n1. Open the following file\r\n`x-pack/plugins/observability_solution/apm/server/routes/correlations/queries/fetch_duration_histogram_range_steps.ts`\r\n2. Modify L61 and L118 changing the initial two values passed to\r\n`getHistogramRangeSteps` to 0.\r\nLike `getHistogramRangeSteps(0, 0, steps)`.\r\nIt doesn't matter the order, if one of the params is at 0 it won't\r\nrender anything.\r\n3. Revert the change and check if the chart is being rendered.","sha":"917473f8321fd56b90f18e5a88d643d5abb7eb29","branchLabelMapping":{"^v8.16.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:fix","apm:charts","ci:project-deploy-observability","Team:obs-ux-infra_services","v8.15.0","v8.16.0","backport:version"],"title":"[APM UI] Fix Latency distribution chart breaks due to transaction durations of value 0","number":191994,"url":"https://github.com/elastic/kibana/pull/191994","mergeCommit":{"message":"[APM UI] Fix Latency distribution chart breaks due to transaction durations of value 0 (#191994)\n\n## Summary\r\nFixes: https://github.com/elastic/kibana/issues/184256\r\n\r\nThis PR fixes the APM latency distribution chart not being able to\r\nrender when we had any duration value as 0, to fix it, we now check if\r\nit's 0 and override it with 1.\r\n\r\n|Before|After|\r\n|-|-|\r\n\r\n|![image](https://github.com/user-attachments/assets/df224a1d-a669-4ea8-ad0e-9f81a82b904a)|![image](https://github.com/user-attachments/assets/cbf6957c-df6f-4f71-8f96-7985279912fa)|\r\n\r\n## Test steps\r\n1. Open the following file\r\n`x-pack/plugins/observability_solution/apm/server/routes/correlations/queries/fetch_duration_histogram_range_steps.ts`\r\n2. Modify L61 and L118 changing the initial two values passed to\r\n`getHistogramRangeSteps` to 0.\r\nLike `getHistogramRangeSteps(0, 0, steps)`.\r\nIt doesn't matter the order, if one of the params is at 0 it won't\r\nrender anything.\r\n3. Revert the change and check if the chart is being rendered.","sha":"917473f8321fd56b90f18e5a88d643d5abb7eb29"}},"sourceBranch":"main","suggestedTargetBranches":["8.15"],"targetPullRequestStates":[{"branch":"8.15","label":"v8.15.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v8.16.0","branchLabelMappingKey":"^v8.16.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/191994","number":191994,"mergeCommit":{"message":"[APM UI] Fix Latency distribution chart breaks due to transaction durations of value 0 (#191994)\n\n## Summary\r\nFixes: https://github.com/elastic/kibana/issues/184256\r\n\r\nThis PR fixes the APM latency distribution chart not being able to\r\nrender when we had any duration value as 0, to fix it, we now check if\r\nit's 0 and override it with 1.\r\n\r\n|Before|After|\r\n|-|-|\r\n\r\n|![image](https://github.com/user-attachments/assets/df224a1d-a669-4ea8-ad0e-9f81a82b904a)|![image](https://github.com/user-attachments/assets/cbf6957c-df6f-4f71-8f96-7985279912fa)|\r\n\r\n## Test steps\r\n1. Open the following file\r\n`x-pack/plugins/observability_solution/apm/server/routes/correlations/queries/fetch_duration_histogram_range_steps.ts`\r\n2. Modify L61 and L118 changing the initial two values passed to\r\n`getHistogramRangeSteps` to 0.\r\nLike `getHistogramRangeSteps(0, 0, steps)`.\r\nIt doesn't matter the order, if one of the params is at 0 it won't\r\nrender anything.\r\n3. Revert the change and check if the chart is being rendered.","sha":"917473f8321fd56b90f18e5a88d643d5abb7eb29"}}]}] BACKPORT--> Co-authored-by: Sergi Romeu <sergi.romeu@elastic.co>
Summary
Fixes: #184256
This PR fixes the APM latency distribution chart not being able to render when we had any duration value as 0, to fix it, we now check if it's 0 and override it with 1.
Test steps
x-pack/plugins/observability_solution/apm/server/routes/correlations/queries/fetch_duration_histogram_range_steps.ts
getHistogramRangeSteps
to 0.Like
getHistogramRangeSteps(0, 0, steps)
.It doesn't matter the order, if one of the params is at 0 it won't render anything.