-
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
[Security Solution] Add support for GET requests to the Detection Engine health API #159970
[Security Solution] Add support for GET requests to the Detection Engine health API #159970
Conversation
Pinging @elastic/security-solution (Team: SecuritySolution) |
Pinging @elastic/security-detections-response (Team:Detections and Resp) |
968d52c
to
3a7f3cb
Compare
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.
@banderror The changes look straightforward and work locally as expected 👍
...urity_solution/common/detection_engine/rule_monitoring/api/detection_engine_health/README.md
Show resolved
Hide resolved
...urity_solution/common/detection_engine/rule_monitoring/api/detection_engine_health/README.md
Show resolved
Hide resolved
3a7f3cb
to
5be87d1
Compare
💛 Build succeeded, but was flaky
Failed CI StepsTest Failures
Metrics [docs]Unknown metric groupsESLint disabled line counts
Total ESLint disabled count
History
To update your PR or re-run it, just comment with: cc @banderror |
…ine health API (elastic#159970) **Partially addresses:** elastic#125642 ## Summary The PoC of the Detection Engine health API has been implemented in elastic#157155. Now, we need to integrate it into the [support-diagnostics](https://github.com/elastic/support-diagnostics) tool. It looks like the tool requires the APIs it calls to be callable with the `GET` verb. This PR makes it possible to call 2 out of 3 health endpoints with `GET`: ```txt GET /internal/detection_engine/health/_cluster ``` ```txt GET /internal/detection_engine/health/_space ``` The `GET` routes don't accept any parameters and use the default parameters instead: - interval: `last_day` - granularity: `hour` - debug: `false` ### Checklist - [x] [Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html) was added for features that require explanation or tutorials - [ ] [Unit or functional tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html) were updated or added to match the most common scenarios ### For maintainers - [x] This was checked for breaking API changes and was [labeled appropriately](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process) (cherry picked from commit 7047f24)
💚 All backports created successfully
Note: Successful backport PRs will be merged automatically after passing CI. Questions ?Please refer to the Backport tool documentation |
…on Engine health API (#159970) (#160023) # Backport This will backport the following commits from `main` to `8.8`: - [[Security Solution] Add support for GET requests to the Detection Engine health API (#159970)](#159970) <!--- Backport version: 8.9.7 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Georgii Gorbachev","email":"[email protected]"},"sourceCommit":{"committedDate":"2023-06-20T14:03:27Z","message":"[Security Solution] Add support for GET requests to the Detection Engine health API (#159970)\n\n**Partially addresses:** https://github.com/elastic/kibana/issues/125642\r\n\r\n## Summary\r\n\r\nThe PoC of the Detection Engine health API has been implemented in\r\nhttps://github.com//pull/157155. Now, we need to integrate\r\nit into the\r\n[support-diagnostics](https://github.com/elastic/support-diagnostics)\r\ntool. It looks like the tool requires the APIs it calls to be callable\r\nwith the `GET` verb.\r\n\r\nThis PR makes it possible to call 2 out of 3 health endpoints with\r\n`GET`:\r\n\r\n```txt\r\nGET /internal/detection_engine/health/_cluster\r\n```\r\n\r\n```txt\r\nGET /internal/detection_engine/health/_space\r\n```\r\n\r\nThe `GET` routes don't accept any parameters and use the default\r\nparameters instead:\r\n\r\n- interval: `last_day`\r\n- granularity: `hour`\r\n- debug: `false`\r\n\r\n\r\n### Checklist\r\n\r\n- [x]\r\n[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)\r\nwas added for features that require explanation or tutorials\r\n- [ ] [Unit or functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere updated or added to match the most common scenarios\r\n\r\n### For maintainers\r\n\r\n- [x] This was checked for breaking API changes and was [labeled\r\nappropriately](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)","sha":"7047f24c1743a2a98e22e332403c5260d6062374","branchLabelMapping":{"^v8.9.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","Team:Detections and Resp","Team: SecuritySolution","Feature:Rule Monitoring","Team:Detection Rule Management","v8.9.0","v8.8.2"],"number":159970,"url":"https://github.com/elastic/kibana/pull/159970","mergeCommit":{"message":"[Security Solution] Add support for GET requests to the Detection Engine health API (#159970)\n\n**Partially addresses:** https://github.com/elastic/kibana/issues/125642\r\n\r\n## Summary\r\n\r\nThe PoC of the Detection Engine health API has been implemented in\r\nhttps://github.com//pull/157155. Now, we need to integrate\r\nit into the\r\n[support-diagnostics](https://github.com/elastic/support-diagnostics)\r\ntool. It looks like the tool requires the APIs it calls to be callable\r\nwith the `GET` verb.\r\n\r\nThis PR makes it possible to call 2 out of 3 health endpoints with\r\n`GET`:\r\n\r\n```txt\r\nGET /internal/detection_engine/health/_cluster\r\n```\r\n\r\n```txt\r\nGET /internal/detection_engine/health/_space\r\n```\r\n\r\nThe `GET` routes don't accept any parameters and use the default\r\nparameters instead:\r\n\r\n- interval: `last_day`\r\n- granularity: `hour`\r\n- debug: `false`\r\n\r\n\r\n### Checklist\r\n\r\n- [x]\r\n[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)\r\nwas added for features that require explanation or tutorials\r\n- [ ] [Unit or functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere updated or added to match the most common scenarios\r\n\r\n### For maintainers\r\n\r\n- [x] This was checked for breaking API changes and was [labeled\r\nappropriately](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)","sha":"7047f24c1743a2a98e22e332403c5260d6062374"}},"sourceBranch":"main","suggestedTargetBranches":["8.8"],"targetPullRequestStates":[{"branch":"main","label":"v8.9.0","labelRegex":"^v8.9.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/159970","number":159970,"mergeCommit":{"message":"[Security Solution] Add support for GET requests to the Detection Engine health API (#159970)\n\n**Partially addresses:** https://github.com/elastic/kibana/issues/125642\r\n\r\n## Summary\r\n\r\nThe PoC of the Detection Engine health API has been implemented in\r\nhttps://github.com//pull/157155. Now, we need to integrate\r\nit into the\r\n[support-diagnostics](https://github.com/elastic/support-diagnostics)\r\ntool. It looks like the tool requires the APIs it calls to be callable\r\nwith the `GET` verb.\r\n\r\nThis PR makes it possible to call 2 out of 3 health endpoints with\r\n`GET`:\r\n\r\n```txt\r\nGET /internal/detection_engine/health/_cluster\r\n```\r\n\r\n```txt\r\nGET /internal/detection_engine/health/_space\r\n```\r\n\r\nThe `GET` routes don't accept any parameters and use the default\r\nparameters instead:\r\n\r\n- interval: `last_day`\r\n- granularity: `hour`\r\n- debug: `false`\r\n\r\n\r\n### Checklist\r\n\r\n- [x]\r\n[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)\r\nwas added for features that require explanation or tutorials\r\n- [ ] [Unit or functional\r\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\r\nwere updated or added to match the most common scenarios\r\n\r\n### For maintainers\r\n\r\n- [x] This was checked for breaking API changes and was [labeled\r\nappropriately](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)","sha":"7047f24c1743a2a98e22e332403c5260d6062374"}},{"branch":"8.8","label":"v8.8.2","labelRegex":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> Co-authored-by: Georgii Gorbachev <[email protected]>
…PI (#160137) **Partially addresses:** #125642 ## Summary - fixes typos noticed by @maximpn in #159970 (comment) - adds additional docs for #159875
Partially addresses: #125642
Summary
The PoC of the Detection Engine health API has been implemented in #157155. Now, we need to integrate it into the support-diagnostics tool. It looks like the tool requires the APIs it calls to be callable with the
GET
verb.This PR makes it possible to call 2 out of 3 health endpoints with
GET
:The
GET
routes don't accept any parameters and use the default parameters instead:last_day
hour
false
Checklist
For maintainers