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

[ML] Explain Log Rate Spikes: Additional unit tests. #147451

Merged
merged 9 commits into from
Dec 21, 2022

Conversation

walterra
Copy link
Contributor

@walterra walterra commented Dec 13, 2022

Summary

Part of #147170.

This breaks out inline code in x-pack/plugins/aiops/server/routes/explain_log_rate_spikes.ts to functions in separate files and adds jest unit tests for each function. The mocks used for jest unit tests are used as expected data in the API integration tests. This allows to make sure that the static mocks are still up to date should we have to update API integration tests based on upstream tests.

Checklist

@walterra walterra self-assigned this Dec 13, 2022
@walterra walterra force-pushed the 146162a-fix-item-set-filter branch 5 times, most recently from 79604ef to a86db3e Compare December 15, 2022 09:46
@walterra walterra changed the title [ML] Explain Log Rate Spikes: Grouping fixes and additional unit tests. [ML] Explain Log Rate Spikes: Additional unit tests. Dec 15, 2022
@walterra walterra mentioned this pull request Dec 15, 2022
14 tasks
@walterra walterra force-pushed the 146162a-fix-item-set-filter branch 5 times, most recently from c9df488 to 97a2a1c Compare December 20, 2022 15:34
@walterra walterra added release_note:skip Skip the PR/issue when compiling release notes Feature:ML/AIOps ML AIOps features: Change Point Detection, Log Pattern Analysis, Log Rate Analysis v8.7.0 :ml labels Dec 20, 2022
@walterra walterra marked this pull request as ready for review December 20, 2022 15:46
@walterra walterra requested a review from a team as a code owner December 20, 2022 15:46
@elasticmachine
Copy link
Contributor

Pinging @elastic/ml-ui (:ml)

@kibana-ci
Copy link
Collaborator

💚 Build Succeeded

Metrics [docs]

Module Count

Fewer modules leads to a faster build time

id before after diff
aiops 460 461 +1
Unknown metric groups

ESLint disabled in files

id before after diff
osquery 1 2 +1

ESLint disabled line counts

id before after diff
enterpriseSearch 19 21 +2
fleet 61 67 +6
osquery 109 115 +6
securitySolution 439 445 +6
total +20

Total ESLint disabled count

id before after diff
enterpriseSearch 20 22 +2
fleet 70 76 +6
osquery 110 117 +7
securitySolution 515 521 +6
total +21

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

cc @walterra

Copy link
Contributor

@peteharverson peteharverson left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

@alvarezmelissa87 alvarezmelissa87 left a comment

Choose a reason for hiding this comment

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

LGTM ⚡

@walterra walterra merged commit d7be514 into elastic:main Dec 21, 2022
@kibanamachine kibanamachine added the backport:skip This commit does not require backporting label Dec 21, 2022
@walterra walterra deleted the 146162a-fix-item-set-filter branch December 21, 2022 21:37
simianhacker pushed a commit to simianhacker/kibana that referenced this pull request Dec 22, 2022
This breaks out inline code in
`x-pack/plugins/aiops/server/routes/explain_log_rate_spikes.ts` to
functions in separate files and adds jest unit tests for each function.
The mocks used for jest unit tests are used as expected data in the API
integration tests. This allows to make sure that the static mocks are
still up to date should we have to update API integration tests based on
upstream tests.
crespocarlos pushed a commit to crespocarlos/kibana that referenced this pull request Dec 23, 2022
This breaks out inline code in
`x-pack/plugins/aiops/server/routes/explain_log_rate_spikes.ts` to
functions in separate files and adds jest unit tests for each function.
The mocks used for jest unit tests are used as expected data in the API
integration tests. This allows to make sure that the static mocks are
still up to date should we have to update API integration tests based on
upstream tests.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:skip This commit does not require backporting Feature:ML/AIOps ML AIOps features: Change Point Detection, Log Pattern Analysis, Log Rate Analysis :ml release_note:skip Skip the PR/issue when compiling release notes v8.7.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants