[SIEM] Uses a dedicated index for job creation instead of the shared anomaly index#42297
Merged
FrankHassanabad merged 2 commits intoelastic:masterfrom Jul 30, 2019
Conversation
spong
approved these changes
Jul 30, 2019
Member
spong
left a comment
There was a problem hiding this comment.
Checked out, tested locally, and verified the following:
- Both setup API calls
/api/ml/modules/setup/siem_auditbeat_ecs&/api/ml/modules/setup/siem_winlogbeat_ecsnow includeuseDedicatedIndex: truein the request payload - That the dedicated indices exist after job creation:
green open .ml-anomalies-custom-siem-api-suspicious_login_activity_ecs ru8vhC_bT3Smf2b-G0eYfQ 1 0 0 0 230b 230b green open .ml-anomalies-custom-siem-api-rare_process_windows_ecs zDYUqYSiSVaNValzvsp-LQ 1 0 0 0 230b 230b green open .ml-anomalies-custom-siem-api-rare_process_linux_ecs 5jVD96kWTymOl1Ye8EiKbw 1 0 0 0 230b 230b
- That the
ml-anomalies-sharedis no longer polluted with additional fields from the above jobs
LGTM! 👍
Contributor
💚 Build Succeeded |
FrankHassanabad
added a commit
to FrankHassanabad/kibana
that referenced
this pull request
Jul 30, 2019
## Summary Summarize your PR. If it involves visual changes include a screenshot or gif. ### Checklist Uses a dedicated index for job creation instead of the shared anomaly index. Previously we used only `.ml-anomalies-shared` but this can cause a mapping clash from users who might have put different data types into that index already. See: https://www.elastic.co/guide/en/elastic-stack-overview/7.x/ml-mappingclash.html This makes all creation of all SIEM jobs use a dedicated index from this point moving forward. For testing: * Delete any existing jobs from your server and any test data in the ML UI: * Go to dev tools and run: `GET /_cat/indices/.ml-anomalies-custom-*?v` and verify you do not have any custom indexes prefixed with an existing SIEM job * Click the "Anomaly Button" in the SIEM application to re-install the jobs * Go to dev tools and run: `GET /_cat/indices/.ml-*?v` Expectations are that you will see these indexes created: ```ts health status index uuid pri rep docs.count docs.deleted store.size pri.store.size green open .ml-anomalies-custom-siem-api-suspicious_login_activity_ecs 7ksvxOpgQ8WOG91NA_o8Eg 1 0 1474 1905 601.8kb 601.8kb green open .ml-anomalies-custom-siem-api-rare_process_windows_ecs Q_8xC5orR-eZSlXQJvmL9w 1 0 1655 474 454.3kb 454.3kb green open .ml-anomalies-custom-siem-api-rare_process_linux_ecs k_MwtbZIRbSkQxh6lcXIKg 1 0 1845 3832 1mb 1mb ``` ~~- [ ] This was checked for cross-browser compatibility, [including a check against IE11](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#cross-browser-compatibility)~~ - [x] Any text added follows [EUI's writing guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses sentence case text and includes [i18n support](https://github.com/elastic/kibana/blob/master/packages/kbn-i18n/README.md) ~~- [ ] [Documentation](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#writing-documentation) was added for features that require explanation or tutorials~~ ~~- [ ] [Unit or functional tests](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#cross-browser-compatibility) were updated or added to match the most common scenarios~~ ~~- [ ] This was checked for [keyboard-only and screenreader accessibility](https://developer.mozilla.org/en-US/docs/Learn/Tools_and_testing/Cross_browser_testing/Accessibility#Accessibility_testing_checklist)~~ ### For maintainers ~~- [ ] This was checked for breaking API changes and was [labeled appropriately](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#release-notes-process)~~ - [x] This includes a feature addition or change that requires a release note and was [labeled appropriately](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#release-notes-process)
FrankHassanabad
added a commit
that referenced
this pull request
Jul 31, 2019
## Summary Summarize your PR. If it involves visual changes include a screenshot or gif. ### Checklist Uses a dedicated index for job creation instead of the shared anomaly index. Previously we used only `.ml-anomalies-shared` but this can cause a mapping clash from users who might have put different data types into that index already. See: https://www.elastic.co/guide/en/elastic-stack-overview/7.x/ml-mappingclash.html This makes all creation of all SIEM jobs use a dedicated index from this point moving forward. For testing: * Delete any existing jobs from your server and any test data in the ML UI: * Go to dev tools and run: `GET /_cat/indices/.ml-anomalies-custom-*?v` and verify you do not have any custom indexes prefixed with an existing SIEM job * Click the "Anomaly Button" in the SIEM application to re-install the jobs * Go to dev tools and run: `GET /_cat/indices/.ml-*?v` Expectations are that you will see these indexes created: ```ts health status index uuid pri rep docs.count docs.deleted store.size pri.store.size green open .ml-anomalies-custom-siem-api-suspicious_login_activity_ecs 7ksvxOpgQ8WOG91NA_o8Eg 1 0 1474 1905 601.8kb 601.8kb green open .ml-anomalies-custom-siem-api-rare_process_windows_ecs Q_8xC5orR-eZSlXQJvmL9w 1 0 1655 474 454.3kb 454.3kb green open .ml-anomalies-custom-siem-api-rare_process_linux_ecs k_MwtbZIRbSkQxh6lcXIKg 1 0 1845 3832 1mb 1mb ``` ~~- [ ] This was checked for cross-browser compatibility, [including a check against IE11](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#cross-browser-compatibility)~~ - [x] Any text added follows [EUI's writing guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses sentence case text and includes [i18n support](https://github.com/elastic/kibana/blob/master/packages/kbn-i18n/README.md) ~~- [ ] [Documentation](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#writing-documentation) was added for features that require explanation or tutorials~~ ~~- [ ] [Unit or functional tests](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#cross-browser-compatibility) were updated or added to match the most common scenarios~~ ~~- [ ] This was checked for [keyboard-only and screenreader accessibility](https://developer.mozilla.org/en-US/docs/Learn/Tools_and_testing/Cross_browser_testing/Accessibility#Accessibility_testing_checklist)~~ ### For maintainers ~~- [ ] This was checked for breaking API changes and was [labeled appropriately](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#release-notes-process)~~ - [x] This includes a feature addition or change that requires a release note and was [labeled appropriately](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#release-notes-process)
jloleysens
added a commit
to jloleysens/kibana
that referenced
this pull request
Jul 31, 2019
…-or-edit-existing-rollup-job * 'master' of github.com:elastic/kibana: (114 commits) [ML] Fixing empty index pattern list (elastic#42299) [Markdown] Shim new platform - cleanup plugin (elastic#41760) [Code] Enable hierarchicalDocumentSymbolSupport for java language server (elastic#42233) Add New Platform mocks for data plugin (elastic#42261) Http server route handler implementation (elastic#41894) [SR] Allow custom index pattern to be used instead of selectable list when choosing indices to restore (elastic#41534) [Code] distributed Code abstraction (elastic#41374) [SIEM] Sets page titles to the current page you are on (elastic#42157) Saved Objects export API stable type order (elastic#42310) cancellation of interpreter execution (elastic#40238) [SIEM] Fixes a crash when Machine Learning influencers is an undefined value (elastic#42198) Changed the job to work with a dedicated index (elastic#42297) FTR: fix testSubjects.missingOrFail (elastic#42290) Increase retry timeout to prevent flaky tests (elastic#42291) Spaces - make space a hidden saved object type (elastic#41688) Allow applications to register feature privileges which are excluded from the base privileges (elastic#41300) Disable flaky log column reorder test (elastic#42285) Fixing add element in element reducer (elastic#42276) Fix infinite loop (elastic#42228) [Maps][File upload] Remove geojson deep clone logic, handle on maps side (elastic#41835) ...
spong
pushed a commit
to spong/kibana
that referenced
this pull request
Aug 1, 2019
## Summary Summarize your PR. If it involves visual changes include a screenshot or gif. ### Checklist Uses a dedicated index for job creation instead of the shared anomaly index. Previously we used only `.ml-anomalies-shared` but this can cause a mapping clash from users who might have put different data types into that index already. See: https://www.elastic.co/guide/en/elastic-stack-overview/7.x/ml-mappingclash.html This makes all creation of all SIEM jobs use a dedicated index from this point moving forward. For testing: * Delete any existing jobs from your server and any test data in the ML UI: * Go to dev tools and run: `GET /_cat/indices/.ml-anomalies-custom-*?v` and verify you do not have any custom indexes prefixed with an existing SIEM job * Click the "Anomaly Button" in the SIEM application to re-install the jobs * Go to dev tools and run: `GET /_cat/indices/.ml-*?v` Expectations are that you will see these indexes created: ```ts health status index uuid pri rep docs.count docs.deleted store.size pri.store.size green open .ml-anomalies-custom-siem-api-suspicious_login_activity_ecs 7ksvxOpgQ8WOG91NA_o8Eg 1 0 1474 1905 601.8kb 601.8kb green open .ml-anomalies-custom-siem-api-rare_process_windows_ecs Q_8xC5orR-eZSlXQJvmL9w 1 0 1655 474 454.3kb 454.3kb green open .ml-anomalies-custom-siem-api-rare_process_linux_ecs k_MwtbZIRbSkQxh6lcXIKg 1 0 1845 3832 1mb 1mb ``` ~~- [ ] This was checked for cross-browser compatibility, [including a check against IE11](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#cross-browser-compatibility)~~ - [x] Any text added follows [EUI's writing guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses sentence case text and includes [i18n support](https://github.com/elastic/kibana/blob/master/packages/kbn-i18n/README.md) ~~- [ ] [Documentation](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#writing-documentation) was added for features that require explanation or tutorials~~ ~~- [ ] [Unit or functional tests](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#cross-browser-compatibility) were updated or added to match the most common scenarios~~ ~~- [ ] This was checked for [keyboard-only and screenreader accessibility](https://developer.mozilla.org/en-US/docs/Learn/Tools_and_testing/Cross_browser_testing/Accessibility#Accessibility_testing_checklist)~~ ### For maintainers ~~- [ ] This was checked for breaking API changes and was [labeled appropriately](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#release-notes-process)~~ - [x] This includes a feature addition or change that requires a release note and was [labeled appropriately](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#release-notes-process)
spong
added a commit
that referenced
this pull request
Aug 2, 2019
## Summary Summarize your PR. If it involves visual changes include a screenshot or gif. ### Checklist Uses a dedicated index for job creation instead of the shared anomaly index. Previously we used only `.ml-anomalies-shared` but this can cause a mapping clash from users who might have put different data types into that index already. See: https://www.elastic.co/guide/en/elastic-stack-overview/7.x/ml-mappingclash.html This makes all creation of all SIEM jobs use a dedicated index from this point moving forward. For testing: * Delete any existing jobs from your server and any test data in the ML UI: * Go to dev tools and run: `GET /_cat/indices/.ml-anomalies-custom-*?v` and verify you do not have any custom indexes prefixed with an existing SIEM job * Click the "Anomaly Button" in the SIEM application to re-install the jobs * Go to dev tools and run: `GET /_cat/indices/.ml-*?v` Expectations are that you will see these indexes created: ```ts health status index uuid pri rep docs.count docs.deleted store.size pri.store.size green open .ml-anomalies-custom-siem-api-suspicious_login_activity_ecs 7ksvxOpgQ8WOG91NA_o8Eg 1 0 1474 1905 601.8kb 601.8kb green open .ml-anomalies-custom-siem-api-rare_process_windows_ecs Q_8xC5orR-eZSlXQJvmL9w 1 0 1655 474 454.3kb 454.3kb green open .ml-anomalies-custom-siem-api-rare_process_linux_ecs k_MwtbZIRbSkQxh6lcXIKg 1 0 1845 3832 1mb 1mb ``` ~~- [ ] This was checked for cross-browser compatibility, [including a check against IE11](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#cross-browser-compatibility)~~ - [x] Any text added follows [EUI's writing guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses sentence case text and includes [i18n support](https://github.com/elastic/kibana/blob/master/packages/kbn-i18n/README.md) ~~- [ ] [Documentation](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#writing-documentation) was added for features that require explanation or tutorials~~ ~~- [ ] [Unit or functional tests](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#cross-browser-compatibility) were updated or added to match the most common scenarios~~ ~~- [ ] This was checked for [keyboard-only and screenreader accessibility](https://developer.mozilla.org/en-US/docs/Learn/Tools_and_testing/Cross_browser_testing/Accessibility#Accessibility_testing_checklist)~~ ### For maintainers ~~- [ ] This was checked for breaking API changes and was [labeled appropriately](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#release-notes-process)~~ - [x] This includes a feature addition or change that requires a release note and was [labeled appropriately](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#release-notes-process)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Summarize your PR. If it involves visual changes include a screenshot or gif.
Checklist
Uses a dedicated index for job creation instead of the shared anomaly index.
Previously we used only
.ml-anomalies-sharedbut this can cause a mapping clash from users who might have put different data types into that index already.See:
https://www.elastic.co/guide/en/elastic-stack-overview/7.x/ml-mappingclash.html
This makes all creation of all SIEM jobs use a dedicated index from this point moving forward.
For testing:
GET /_cat/indices/.ml-anomalies-custom-*?vand verify you do not have any custom indexes prefixed with an existing SIEM jobGET /_cat/indices/.ml-*?vExpectations are that you will see these indexes created:
- [ ] This was checked for cross-browser compatibility, including a check against IE11- [ ] Documentation was added for features that require explanation or tutorials- [ ] Unit or functional tests were updated or added to match the most common scenarios- [ ] This was checked for keyboard-only and screenreader accessibilityFor maintainers
- [ ] This was checked for breaking API changes and was labeled appropriately