-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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] Fix tls alert data !! #212758
Conversation
Pinging @elastic/obs-ux-management-team (Team:obs-ux-management) |
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.
This appears to work ok, but I did note that I can't edit the TLS rule in the management page.
Discussed this with @shahzad31 offline, will wait for him to fix this and then this should be ready.
x-pack/solutions/observability/plugins/synthetics/common/runtime_types/ping/observer.ts
Show resolved
Hide resolved
💛 Build succeeded, but was flaky
Failed CI StepsMetrics [docs]Async chunks
History
|
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
Starting backport for target branches: 8.18, 9.0 |
💔 All backports failed
Manual backportTo create the backport manually run:
Questions ?Please refer to the Backport tool documentation |
### Summary This PR improves and fixes the TLS alert data handling in the Synthetics plugin. Key updates include: ### Code changes 1. **Request Body Updates**: - Added `agent.name`. - Changed optional chaining to direct property access for `ping.monitor.name`, `ping.monitor.id`, and `ping.observer.name`. - Added `ping.agent.name`. 2. **Cert Type Adjustments**: - Added fields: `monitorName`, `monitorId`, `monitorType`, `locationId`, `locationName`, `@timestamp`, `hostName`. 3. **Observer Codec**: - Ensured `name` and `geo.name` are required fields. 4. **Monitor Type and Ping Type**: - Added `name` to `MonitorType`. - Moved `@timestamp` to required fields in `PingType`. 7. **Message Utils**: - Adjusted `getCertSummary` and `getTLSAlertDocument` so that we can properly generate alert document (cherry picked from commit 80f4aab) # Conflicts: # x-pack/solutions/observability/plugins/synthetics/common/requests/get_certs_request_body.ts
💚 All backports created successfully
Note: Successful backport PRs will be merged automatically after passing CI. Questions ?Please refer to the Backport tool documentation |
### Summary This PR improves and fixes the TLS alert data handling in the Synthetics plugin. Key updates include: ### Code changes 1. **Request Body Updates**: - Added `agent.name`. - Changed optional chaining to direct property access for `ping.monitor.name`, `ping.monitor.id`, and `ping.observer.name`. - Added `ping.agent.name`. 2. **Cert Type Adjustments**: - Added fields: `monitorName`, `monitorId`, `monitorType`, `locationId`, `locationName`, `@timestamp`, `hostName`. 3. **Observer Codec**: - Ensured `name` and `geo.name` are required fields. 4. **Monitor Type and Ping Type**: - Added `name` to `MonitorType`. - Moved `@timestamp` to required fields in `PingType`. 7. **Message Utils**: - Adjusted `getCertSummary` and `getTLSAlertDocument` so that we can properly generate alert document (cherry picked from commit 80f4aab) # Conflicts: # x-pack/solutions/observability/plugins/synthetics/common/requests/get_certs_request_body.ts # x-pack/solutions/observability/plugins/synthetics/server/alert_rules/tls_rule/types.ts
Starting backport for target branches: 8.16, 8.17, 8.18, 8.x, 9.0 |
Starting backport for target branches: 8.16, 8.17, 8.18, 8.x, 9.0 |
💔 All backports failed
Manual backportTo create the backport manually run:
Questions ?Please refer to the Backport tool documentation |
💔 All backports failed
Manual backportTo create the backport manually run:
Questions ?Please refer to the Backport tool documentation |
💚 All backports created successfully
Note: Successful backport PRs will be merged automatically after passing CI. Questions ?Please refer to the Backport tool documentation |
### Summary This PR improves and fixes the TLS alert data handling in the Synthetics plugin. Key updates include: ### Code changes 1. **Request Body Updates**: - Added `agent.name`. - Changed optional chaining to direct property access for `ping.monitor.name`, `ping.monitor.id`, and `ping.observer.name`. - Added `ping.agent.name`. 2. **Cert Type Adjustments**: - Added fields: `monitorName`, `monitorId`, `monitorType`, `locationId`, `locationName`, `@timestamp`, `hostName`. 3. **Observer Codec**: - Ensured `name` and `geo.name` are required fields. 4. **Monitor Type and Ping Type**: - Added `name` to `MonitorType`. - Moved `@timestamp` to required fields in `PingType`. 7. **Message Utils**: - Adjusted `getCertSummary` and `getTLSAlertDocument` so that we can properly generate alert document (cherry picked from commit 80f4aab) # Conflicts: # x-pack/solutions/observability/plugins/synthetics/common/requests/get_certs_request_body.ts # x-pack/solutions/observability/plugins/synthetics/server/alert_rules/tls_rule/types.ts
# Backport This will backport the following commits from `main` to `8.18`: - [[Synthetics] Fix tls alert data !! (#212758)](#212758) <!--- Backport version: 9.6.6 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sorenlouv/backport) <!--BACKPORT [{"author":{"name":"Shahzad","email":"shahzad31comp@gmail.com"},"sourceCommit":{"committedDate":"2025-03-05T18:40:04Z","message":"[Synthetics] Fix tls alert data !! (#212758)\n\n### Summary\nThis PR improves and fixes the TLS alert data handling in the Synthetics\nplugin. Key updates include:\n\n\n### Code changes\n\n1. **Request Body Updates**:\n - Added `agent.name`.\n- Changed optional chaining to direct property access for\n`ping.monitor.name`, `ping.monitor.id`, and `ping.observer.name`.\n - Added `ping.agent.name`.\n\n2. **Cert Type Adjustments**:\n- Added fields: `monitorName`, `monitorId`, `monitorType`, `locationId`,\n`locationName`, `@timestamp`, `hostName`.\n\n3. **Observer Codec**:\n - Ensured `name` and `geo.name` are required fields.\n\n4. **Monitor Type and Ping Type**:\n - Added `name` to `MonitorType`.\n - Moved `@timestamp` to required fields in `PingType`.\n\n7. **Message Utils**:\n- Adjusted `getCertSummary` and `getTLSAlertDocument` so that we can\nproperly generate alert document","sha":"80f4aab305eb90646f418bc704423308d133d7d2","branchLabelMapping":{"^v9.1.0$":"main","^v8.19.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","v9.0.0","Team:obs-ux-management","backport:version","v8.18.0","v9.1.0"],"title":"[Synthetics] Fix tls alert data !!","number":212758,"url":"https://github.com/elastic/kibana/pull/212758","mergeCommit":{"message":"[Synthetics] Fix tls alert data !! (#212758)\n\n### Summary\nThis PR improves and fixes the TLS alert data handling in the Synthetics\nplugin. Key updates include:\n\n\n### Code changes\n\n1. **Request Body Updates**:\n - Added `agent.name`.\n- Changed optional chaining to direct property access for\n`ping.monitor.name`, `ping.monitor.id`, and `ping.observer.name`.\n - Added `ping.agent.name`.\n\n2. **Cert Type Adjustments**:\n- Added fields: `monitorName`, `monitorId`, `monitorType`, `locationId`,\n`locationName`, `@timestamp`, `hostName`.\n\n3. **Observer Codec**:\n - Ensured `name` and `geo.name` are required fields.\n\n4. **Monitor Type and Ping Type**:\n - Added `name` to `MonitorType`.\n - Moved `@timestamp` to required fields in `PingType`.\n\n7. **Message Utils**:\n- Adjusted `getCertSummary` and `getTLSAlertDocument` so that we can\nproperly generate alert document","sha":"80f4aab305eb90646f418bc704423308d133d7d2"}},"sourceBranch":"main","suggestedTargetBranches":["9.0","8.18"],"targetPullRequestStates":[{"branch":"9.0","label":"v9.0.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.18","label":"v8.18.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/212758","number":212758,"mergeCommit":{"message":"[Synthetics] Fix tls alert data !! (#212758)\n\n### Summary\nThis PR improves and fixes the TLS alert data handling in the Synthetics\nplugin. Key updates include:\n\n\n### Code changes\n\n1. **Request Body Updates**:\n - Added `agent.name`.\n- Changed optional chaining to direct property access for\n`ping.monitor.name`, `ping.monitor.id`, and `ping.observer.name`.\n - Added `ping.agent.name`.\n\n2. **Cert Type Adjustments**:\n- Added fields: `monitorName`, `monitorId`, `monitorType`, `locationId`,\n`locationName`, `@timestamp`, `hostName`.\n\n3. **Observer Codec**:\n - Ensured `name` and `geo.name` are required fields.\n\n4. **Monitor Type and Ping Type**:\n - Added `name` to `MonitorType`.\n - Moved `@timestamp` to required fields in `PingType`.\n\n7. **Message Utils**:\n- Adjusted `getCertSummary` and `getTLSAlertDocument` so that we can\nproperly generate alert document","sha":"80f4aab305eb90646f418bc704423308d133d7d2"}}]}] BACKPORT-->
# Backport This will backport the following commits from `main` to `8.x`: - [[Synthetics] Fix tls alert data !! (#212758)](#212758) <!--- Backport version: 9.6.6 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sorenlouv/backport) <!--BACKPORT [{"author":{"name":"Shahzad","email":"shahzad31comp@gmail.com"},"sourceCommit":{"committedDate":"2025-03-05T18:40:04Z","message":"[Synthetics] Fix tls alert data !! (#212758)\n\n### Summary\nThis PR improves and fixes the TLS alert data handling in the Synthetics\nplugin. Key updates include:\n\n\n### Code changes\n\n1. **Request Body Updates**:\n - Added `agent.name`.\n- Changed optional chaining to direct property access for\n`ping.monitor.name`, `ping.monitor.id`, and `ping.observer.name`.\n - Added `ping.agent.name`.\n\n2. **Cert Type Adjustments**:\n- Added fields: `monitorName`, `monitorId`, `monitorType`, `locationId`,\n`locationName`, `@timestamp`, `hostName`.\n\n3. **Observer Codec**:\n - Ensured `name` and `geo.name` are required fields.\n\n4. **Monitor Type and Ping Type**:\n - Added `name` to `MonitorType`.\n - Moved `@timestamp` to required fields in `PingType`.\n\n7. **Message Utils**:\n- Adjusted `getCertSummary` and `getTLSAlertDocument` so that we can\nproperly generate alert document","sha":"80f4aab305eb90646f418bc704423308d133d7d2","branchLabelMapping":{"^v9.1.0$":"main","^v8.19.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","v9.0.0","backport:prev-minor","backport:prev-major","Team:obs-ux-management","v8.18.0","v9.1.0"],"title":"[Synthetics] Fix tls alert data !!","number":212758,"url":"https://github.com/elastic/kibana/pull/212758","mergeCommit":{"message":"[Synthetics] Fix tls alert data !! (#212758)\n\n### Summary\nThis PR improves and fixes the TLS alert data handling in the Synthetics\nplugin. Key updates include:\n\n\n### Code changes\n\n1. **Request Body Updates**:\n - Added `agent.name`.\n- Changed optional chaining to direct property access for\n`ping.monitor.name`, `ping.monitor.id`, and `ping.observer.name`.\n - Added `ping.agent.name`.\n\n2. **Cert Type Adjustments**:\n- Added fields: `monitorName`, `monitorId`, `monitorType`, `locationId`,\n`locationName`, `@timestamp`, `hostName`.\n\n3. **Observer Codec**:\n - Ensured `name` and `geo.name` are required fields.\n\n4. **Monitor Type and Ping Type**:\n - Added `name` to `MonitorType`.\n - Moved `@timestamp` to required fields in `PingType`.\n\n7. **Message Utils**:\n- Adjusted `getCertSummary` and `getTLSAlertDocument` so that we can\nproperly generate alert document","sha":"80f4aab305eb90646f418bc704423308d133d7d2"}},"sourceBranch":"main","suggestedTargetBranches":[],"targetPullRequestStates":[{"branch":"9.0","label":"v9.0.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"url":"https://github.com/elastic/kibana/pull/213315","number":213315,"state":"OPEN"},{"branch":"8.18","label":"v8.18.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"url":"https://github.com/elastic/kibana/pull/213317","number":213317,"state":"OPEN"},{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/212758","number":212758,"mergeCommit":{"message":"[Synthetics] Fix tls alert data !! (#212758)\n\n### Summary\nThis PR improves and fixes the TLS alert data handling in the Synthetics\nplugin. Key updates include:\n\n\n### Code changes\n\n1. **Request Body Updates**:\n - Added `agent.name`.\n- Changed optional chaining to direct property access for\n`ping.monitor.name`, `ping.monitor.id`, and `ping.observer.name`.\n - Added `ping.agent.name`.\n\n2. **Cert Type Adjustments**:\n- Added fields: `monitorName`, `monitorId`, `monitorType`, `locationId`,\n`locationName`, `@timestamp`, `hostName`.\n\n3. **Observer Codec**:\n - Ensured `name` and `geo.name` are required fields.\n\n4. **Monitor Type and Ping Type**:\n - Added `name` to `MonitorType`.\n - Moved `@timestamp` to required fields in `PingType`.\n\n7. **Message Utils**:\n- Adjusted `getCertSummary` and `getTLSAlertDocument` so that we can\nproperly generate alert document","sha":"80f4aab305eb90646f418bc704423308d133d7d2"}}]}] BACKPORT-->
Summary
This PR improves and fixes the TLS alert data handling in the Synthetics plugin. Key updates include:
Code changes
Request Body Updates:
agent.name
.ping.monitor.name
,ping.monitor.id
, andping.observer.name
.ping.agent.name
.Cert Type Adjustments:
monitorName
,monitorId
,monitorType
,locationId
,locationName
,@timestamp
,hostName
.Observer Codec:
name
andgeo.name
are required fields.Monitor Type and Ping Type:
name
toMonitorType
.@timestamp
to required fields inPingType
.Message Utils:
getCertSummary
andgetTLSAlertDocument
so that we can properly generate alert document