-
Notifications
You must be signed in to change notification settings - Fork 104
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
create findingIndex bugfix #653
create findingIndex bugfix #653
Conversation
Signed-off-by: Petar Dzepina <[email protected]>
Signed-off-by: Petar Dzepina <[email protected]>
Signed-off-by: Petar Dzepina <[email protected]>
Codecov Report
@@ Coverage Diff @@
## main #653 +/- ##
============================================
- Coverage 76.37% 76.13% -0.25%
Complexity 116 116
============================================
Files 124 124
Lines 6443 6569 +126
Branches 942 972 +30
============================================
+ Hits 4921 5001 +80
- Misses 1040 1072 +32
- Partials 482 496 +14
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
val findingsIndexPattern = dataSources.findingsIndexPattern ?: FINDING_HISTORY_INDEX_PATTERN | ||
if (!clusterService.state().metadata().hasAlias(findingsIndexPattern)) { | ||
if (!clusterService.state().metadata().hasAlias(findingsIndex)) { |
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.
Why do we need to set the findingsIndexPattern
here?
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.
We're using findingsIndexPattern as index name in createIndex method right below. Index is created with pattern as name and is attached to alias during creation(findingIndex)
The backport to
To backport manually, run these commands in your terminal: # Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-2.x 2.x
# Navigate to the new working tree
cd .worktrees/backport-2.x
# Create a new branch
git switch --create backport/backport-653-to-2.x
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 1018fa2332ac7ad66266e19b18039bc7fdb17f80
# Push it to GitHub
git push --set-upstream origin backport/backport-653-to-2.x
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-2.x Then, create a pull request where the |
The backport to
To backport manually, run these commands in your terminal: # Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-2.4 2.4
# Navigate to the new working tree
cd .worktrees/backport-2.4
# Create a new branch
git switch --create backport/backport-653-to-2.4
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 1018fa2332ac7ad66266e19b18039bc7fdb17f80
# Push it to GitHub
git push --set-upstream origin backport/backport-653-to-2.4
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-2.4 Then, create a pull request where the |
* findingIndex create bugfix Signed-off-by: Petar Dzepina <[email protected]> * empty commit Signed-off-by: Petar Dzepina <[email protected]> * IT fix Signed-off-by: Petar Dzepina <[email protected]> Signed-off-by: Petar Dzepina <[email protected]> (cherry picked from commit 1018fa2)
Signed-off-by: Petar Dzepina [email protected]
Issue #, if available:
Description of changes:
Fixed bug where findingIndex would be recreated in some situations because of faulty "exists" check
CheckList:
[ ] Commits are signed per the DCO using --signoff
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.