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

[Synthetics] Added error track trace to status/tls rule context variable !! #198599

Merged
merged 5 commits into from
Nov 1, 2024

Conversation

shahzad31
Copy link
Contributor

@shahzad31 shahzad31 commented Oct 31, 2024

Summary

Fixes #198593

Added error track trace to status/tls rule context variable !!

image

@shahzad31 shahzad31 marked this pull request as ready for review October 31, 2024 18:20
@shahzad31 shahzad31 requested review from a team as code owners October 31, 2024 18:20
@botelastic botelastic bot added ci:project-deploy-observability Create an Observability project Team:obs-ux-management Observability Management User Experience Team labels Nov 1, 2024
@elasticmachine
Copy link
Contributor

Pinging @elastic/obs-ux-management-team (Team:obs-ux-management)

Copy link
Contributor

github-actions bot commented Nov 1, 2024

🤖 GitHub comments

Expand to view the GitHub comments

Just comment with:

  • /oblt-deploy : Deploy a Kibana instance using the Observability test environments.
  • run docs-build : Re-trigger the docs validation. (use unformatted text in the comment!)

Copy link
Member

@maryam-saeidi maryam-saeidi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code LGTM, added some clarification questions as I am not very familiar with the synthetics rule code.

Going to test it locally now.

@@ -51,6 +51,7 @@ export const CertType = t.intersection([
'@timestamp': t.string,
serviceName: t.string,
errorMessage: t.string,
errorStackTrace: t.union([t.string, t.null]),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do we need to add t.null? I am trying to understand how it is different, for example, from errorMessage.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

because, it can also be null in heartbeat data

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So, in heartbeat data, errorMessage is always present but not errorStackTrace? Where do you check the heartbeat data type?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no both can be optional, but error_stack can also be null

Copy link
Member

@maryam-saeidi maryam-saeidi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Worked as expected locally:

image

description: i18n.translate(
'xpack.synthetics.alertRules.monitorStatus.actionVariables.state.lastErrorStack',
{
defaultMessage: 'Monitor last error stack trace.',
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe this way, it would be more readable?

Monitor's last error stack trace.

Copy link
Member

@maryam-saeidi maryam-saeidi Nov 1, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@paulb-elastic @jasonrhodes, who would be the best person to give a quick review of default messages?

This comment is related to the below screenshot, maybe in this instance we just keep it consistent with the rest but in general I was curious about the process

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For our team I would expect this would be DeDe, ie the docs rep assigned to the area.

@elasticmachine
Copy link
Contributor

elasticmachine commented Nov 1, 2024

💚 Build Succeeded

  • Buildkite Build
  • Commit: 403a0c0
  • Kibana Serverless Image: docker.elastic.co/kibana-ci/kibana-serverless:pr-198599-403a0c0e7c7d

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
synthetics 1.1MB 1.1MB +43.0B

History

@shahzad31 shahzad31 merged commit 5544b1a into elastic:main Nov 1, 2024
54 checks passed
@shahzad31 shahzad31 deleted the error-stack-trace branch November 1, 2024 12:55
@kibanamachine
Copy link
Contributor

Starting backport for target branches: 8.16, 8.x

https://github.com/elastic/kibana/actions/runs/11629688364

kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Nov 1, 2024
…ble !! (elastic#198599)

## Summary

Fixes elastic#198593

Added error track trace to status/tls rule context variable !!

<img width="1725" alt="image"
src="https://github.com/user-attachments/assets/d04fb6f3-7505-4a01-8a6f-b1b27d50ecdd">

(cherry picked from commit 5544b1a)
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Nov 1, 2024
…ble !! (elastic#198599)

## Summary

Fixes elastic#198593

Added error track trace to status/tls rule context variable !!

<img width="1725" alt="image"
src="https://github.com/user-attachments/assets/d04fb6f3-7505-4a01-8a6f-b1b27d50ecdd">

(cherry picked from commit 5544b1a)
@kibanamachine
Copy link
Contributor

💚 All backports created successfully

Status Branch Result
8.16
8.x

Note: Successful backport PRs will be merged automatically after passing CI.

Questions ?

Please refer to the Backport tool documentation

kibanamachine added a commit that referenced this pull request Nov 1, 2024
… variable !! (#198599) (#198672)

# Backport

This will backport the following commits from `main` to `8.x`:
- [[Synthetics] Added error track trace to status/tls rule context
variable !! (#198599)](#198599)

<!--- Backport version: 9.4.3 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sqren/backport)

<!--BACKPORT
[{"author":{"name":"Shahzad","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-11-01T12:55:20Z","message":"[Synthetics]
Added error track trace to status/tls rule context variable !!
(#198599)\n\n## Summary\n\nFixes
https://github.com/elastic/kibana/issues/198593\n\nAdded error track
trace to status/tls rule context variable !!\n\n<img width=\"1725\"
alt=\"image\"\nsrc=\"https://github.com/user-attachments/assets/d04fb6f3-7505-4a01-8a6f-b1b27d50ecdd\">","sha":"5544b1a31439cd8e53d431a9b118d1445eeb79a4","branchLabelMapping":{"^v9.0.0$":"main","^v8.17.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:fix","v9.0.0","ci:project-deploy-observability","Team:obs-ux-management","v8.16.0","backport:version","v8.17.0"],"title":"[Synthetics]
Added error track trace to status/tls rule context variable
!!","number":198599,"url":"https://github.com/elastic/kibana/pull/198599","mergeCommit":{"message":"[Synthetics]
Added error track trace to status/tls rule context variable !!
(#198599)\n\n## Summary\n\nFixes
https://github.com/elastic/kibana/issues/198593\n\nAdded error track
trace to status/tls rule context variable !!\n\n<img width=\"1725\"
alt=\"image\"\nsrc=\"https://github.com/user-attachments/assets/d04fb6f3-7505-4a01-8a6f-b1b27d50ecdd\">","sha":"5544b1a31439cd8e53d431a9b118d1445eeb79a4"}},"sourceBranch":"main","suggestedTargetBranches":["8.16","8.x"],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/198599","number":198599,"mergeCommit":{"message":"[Synthetics]
Added error track trace to status/tls rule context variable !!
(#198599)\n\n## Summary\n\nFixes
https://github.com/elastic/kibana/issues/198593\n\nAdded error track
trace to status/tls rule context variable !!\n\n<img width=\"1725\"
alt=\"image\"\nsrc=\"https://github.com/user-attachments/assets/d04fb6f3-7505-4a01-8a6f-b1b27d50ecdd\">","sha":"5544b1a31439cd8e53d431a9b118d1445eeb79a4"}},{"branch":"8.16","label":"v8.16.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.x","label":"v8.17.0","branchLabelMappingKey":"^v8.17.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->

Co-authored-by: Shahzad <[email protected]>
kibanamachine added a commit that referenced this pull request Nov 1, 2024
…t variable !! (#198599) (#198671)

# Backport

This will backport the following commits from `main` to `8.16`:
- [[Synthetics] Added error track trace to status/tls rule context
variable !! (#198599)](#198599)

<!--- Backport version: 9.4.3 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sqren/backport)

<!--BACKPORT
[{"author":{"name":"Shahzad","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-11-01T12:55:20Z","message":"[Synthetics]
Added error track trace to status/tls rule context variable !!
(#198599)\n\n## Summary\n\nFixes
https://github.com/elastic/kibana/issues/198593\n\nAdded error track
trace to status/tls rule context variable !!\n\n<img width=\"1725\"
alt=\"image\"\nsrc=\"https://github.com/user-attachments/assets/d04fb6f3-7505-4a01-8a6f-b1b27d50ecdd\">","sha":"5544b1a31439cd8e53d431a9b118d1445eeb79a4","branchLabelMapping":{"^v9.0.0$":"main","^v8.17.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:fix","v9.0.0","ci:project-deploy-observability","Team:obs-ux-management","v8.16.0","backport:version","v8.17.0"],"title":"[Synthetics]
Added error track trace to status/tls rule context variable
!!","number":198599,"url":"https://github.com/elastic/kibana/pull/198599","mergeCommit":{"message":"[Synthetics]
Added error track trace to status/tls rule context variable !!
(#198599)\n\n## Summary\n\nFixes
https://github.com/elastic/kibana/issues/198593\n\nAdded error track
trace to status/tls rule context variable !!\n\n<img width=\"1725\"
alt=\"image\"\nsrc=\"https://github.com/user-attachments/assets/d04fb6f3-7505-4a01-8a6f-b1b27d50ecdd\">","sha":"5544b1a31439cd8e53d431a9b118d1445eeb79a4"}},"sourceBranch":"main","suggestedTargetBranches":["8.16","8.x"],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/198599","number":198599,"mergeCommit":{"message":"[Synthetics]
Added error track trace to status/tls rule context variable !!
(#198599)\n\n## Summary\n\nFixes
https://github.com/elastic/kibana/issues/198593\n\nAdded error track
trace to status/tls rule context variable !!\n\n<img width=\"1725\"
alt=\"image\"\nsrc=\"https://github.com/user-attachments/assets/d04fb6f3-7505-4a01-8a6f-b1b27d50ecdd\">","sha":"5544b1a31439cd8e53d431a9b118d1445eeb79a4"}},{"branch":"8.16","label":"v8.16.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.x","label":"v8.17.0","branchLabelMappingKey":"^v8.17.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->

Co-authored-by: Shahzad <[email protected]>
nreese pushed a commit to nreese/kibana that referenced this pull request Nov 1, 2024
…ble !! (elastic#198599)

## Summary

Fixes elastic#198593

Added error track trace to status/tls rule context variable !!

<img width="1725" alt="image"
src="https://github.com/user-attachments/assets/d04fb6f3-7505-4a01-8a6f-b1b27d50ecdd">
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:version Backport to applied version labels ci:project-deploy-observability Create an Observability project release_note:fix Team:obs-ux-management Observability Management User Experience Team v8.16.0 v8.17.0 v9.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Synthetics] Add error stack trace in alert context variable !!
6 participants