[SecuritySolution] override timerange for prebuilt templates#82468
Merged
angorayc merged 19 commits intoelastic:masterfrom Nov 16, 2020
Merged
[SecuritySolution] override timerange for prebuilt templates#82468angorayc merged 19 commits intoelastic:masterfrom
angorayc merged 19 commits intoelastic:masterfrom
Conversation
Contributor
Author
|
@elasticmachine merge upstream |
Contributor
Author
|
@elasticmachine merge upstream |
Contributor
Author
|
@elasticmachine merge upstream |
Contributor
Author
|
@elasticmachine merge upstream |
Contributor
|
@elasticmachine merge upstream |
patrykkopycinski
approved these changes
Nov 16, 2020
Contributor
patrykkopycinski
left a comment
There was a problem hiding this comment.
Thank you @angorayc! Tested locally and everything seems to be working fine :)
x-pack/plugins/security_solution/public/timelines/components/open_timeline/helpers.ts
Outdated
Show resolved
Hide resolved
x-pack/plugins/security_solution/public/timelines/components/open_timeline/helpers.ts
Outdated
Show resolved
Hide resolved
…pen_timeline/helpers.ts Co-authored-by: Patryk Kopyciński <contact@patrykkopycinski.com>
…override-timerange
Contributor
💚 Build SucceededMetrics [docs]Async chunks
History
To update your PR or re-run it, just comment with: |
angorayc
added a commit
to angorayc/kibana
that referenced
this pull request
Nov 16, 2020
…#82468) * override timerange for prebuilt templates * add unit test * add unit tests * make sure it is template * check timelineType * overwrite prebuilt template's timerange * update mock path * override with relative timerange * Update x-pack/plugins/security_solution/public/timelines/components/open_timeline/helpers.ts Co-authored-by: Patryk Kopyciński <contact@patrykkopycinski.com> * review Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com> Co-authored-by: Patryk Kopyciński <contact@patrykkopycinski.com>
angorayc
added a commit
to angorayc/kibana
that referenced
this pull request
Nov 16, 2020
…#82468) * override timerange for prebuilt templates * add unit test * add unit tests * make sure it is template * check timelineType * overwrite prebuilt template's timerange * update mock path * override with relative timerange * Update x-pack/plugins/security_solution/public/timelines/components/open_timeline/helpers.ts Co-authored-by: Patryk Kopyciński <contact@patrykkopycinski.com> * review Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com> Co-authored-by: Patryk Kopyciński <contact@patrykkopycinski.com>
angorayc
added a commit
that referenced
this pull request
Nov 16, 2020
…#83453) * override timerange for prebuilt templates * add unit test * add unit tests * make sure it is template * check timelineType * overwrite prebuilt template's timerange * update mock path * override with relative timerange * Update x-pack/plugins/security_solution/public/timelines/components/open_timeline/helpers.ts Co-authored-by: Patryk Kopyciński <contact@patrykkopycinski.com> * review Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com> Co-authored-by: Patryk Kopyciński <contact@patrykkopycinski.com> Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com> Co-authored-by: Patryk Kopyciński <contact@patrykkopycinski.com>
angorayc
added a commit
that referenced
this pull request
Nov 17, 2020
…82468) (#83454) * [SecuritySolution] override timerange for prebuilt templates (#82468) * override timerange for prebuilt templates * add unit test * add unit tests * make sure it is template * check timelineType * overwrite prebuilt template's timerange * update mock path * override with relative timerange * Update x-pack/plugins/security_solution/public/timelines/components/open_timeline/helpers.ts Co-authored-by: Patryk Kopyciński <contact@patrykkopycinski.com> * review Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com> Co-authored-by: Patryk Kopyciński <contact@patrykkopycinski.com> * add limits Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com> Co-authored-by: Patryk Kopyciński <contact@patrykkopycinski.com>
phillipb
added a commit
to phillipb/kibana
that referenced
this pull request
Nov 19, 2020
…ode-details * 'master' of github.com:elastic/kibana: Remove dependency of tests on strict SyntaxKind values (elastic#83440) [SecuritySolution] override timerange for prebuilt templates (elastic#82468) [Enterprise Search] Added a shouldShowActiveForSubroutes option (elastic#83338) [Lens] Make the dimension flyout panel stay close on outside click (elastic#83059) [Security Solution] Gracefully handle errors in detection rules install (elastic#83306) Fix advanced settings category sorting (elastic#83394)
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
Problem:
The timerange of Elastic prebuilt templates are fixed, plus they are immutable from UI, so users cannot change them when needed. It's not useful so we are fixing it in this PR.
Solution is to override the timerange when installing the templates to 24 hours ago to now, so when users duplicate the template,
they will get the same timerange.
Also when user clicking on the prebuilt timelines, we override it again to 24 hours ago to now.
Steps to verify:
kibana/x-pack/plugins/security_solution/server/lib/detection_engine/scriptsChecklist
Delete any items that are not applicable to this PR.