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

Auto expand replicas #539

Merged
merged 1 commit into from
Sep 7, 2023

Conversation

lezzago
Copy link
Member

@lezzago lezzago commented Sep 6, 2023

Description

Auto expand replicas so for single node clusters, it wouldn't try to create a replica and cause the cluster to be yellow

Issues Resolved

N/A

Check List

  • New functionality includes testing.
    • All tests pass
  • New functionality has been documented.
    • New functionality has javadoc added
  • 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.

Signed-off-by: Ashish Agrawal <ashisagr@amazon.com>
@@ -99,9 +101,13 @@ public static String ruleMappings() throws IOException {

public void initRuleIndex(ActionListener<CreateIndexResponse> actionListener, boolean isPrepackaged) throws IOException {
if (!ruleIndexExists(isPrepackaged)) {
Settings indexSettings = Settings.builder()
.put("index.hidden", true)
.put("index.auto_expand_replicas", "0-all")
Copy link
Member

@eirsep eirsep Sep 6, 2023

Choose a reason for hiding this comment

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

was this a miss?

have we already added this setting this for other system indices in SAP?

Copy link
Member Author

Choose a reason for hiding this comment

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

These indices are auto generated, so it would cause single node clusters starting up to immediately be in a yellow state even if they do not use the plugin.

@codecov
Copy link

codecov bot commented Sep 6, 2023

Codecov Report

Merging #539 (c06e818) into main (5178cc0) will decrease coverage by 0.01%.
The diff coverage is 0.00%.

@@             Coverage Diff              @@
##               main     #539      +/-   ##
============================================
- Coverage     25.77%   25.76%   -0.01%     
  Complexity      942      942              
============================================
  Files           252      252              
  Lines         10768    10772       +4     
  Branches       1197     1197              
============================================
  Hits           2775     2775              
- Misses         7746     7750       +4     
  Partials        247      247              
Files Changed Coverage Δ
...opensearch/securityanalytics/util/RuleIndices.java 0.00% <0.00%> (ø)

@sbcd90 sbcd90 merged commit 1003936 into opensearch-project:main Sep 7, 2023
18 of 22 checks passed
opensearch-trigger-bot bot pushed a commit that referenced this pull request Sep 7, 2023
Signed-off-by: Ashish Agrawal <ashisagr@amazon.com>
(cherry picked from commit 1003936)
opensearch-trigger-bot bot pushed a commit that referenced this pull request Sep 7, 2023
Signed-off-by: Ashish Agrawal <ashisagr@amazon.com>
(cherry picked from commit 1003936)
opensearch-trigger-bot bot pushed a commit that referenced this pull request Sep 7, 2023
Signed-off-by: Ashish Agrawal <ashisagr@amazon.com>
(cherry picked from commit 1003936)
opensearch-trigger-bot bot pushed a commit that referenced this pull request Sep 7, 2023
Signed-off-by: Ashish Agrawal <ashisagr@amazon.com>
(cherry picked from commit 1003936)
opensearch-trigger-bot bot pushed a commit that referenced this pull request Sep 7, 2023
Signed-off-by: Ashish Agrawal <ashisagr@amazon.com>
(cherry picked from commit 1003936)
opensearch-trigger-bot bot pushed a commit that referenced this pull request Sep 7, 2023
Signed-off-by: Ashish Agrawal <ashisagr@amazon.com>
(cherry picked from commit 1003936)
opensearch-trigger-bot bot pushed a commit that referenced this pull request Sep 7, 2023
Signed-off-by: Ashish Agrawal <ashisagr@amazon.com>
(cherry picked from commit 1003936)
opensearch-trigger-bot bot pushed a commit that referenced this pull request Sep 7, 2023
Signed-off-by: Ashish Agrawal <ashisagr@amazon.com>
(cherry picked from commit 1003936)
lezzago added a commit that referenced this pull request Sep 11, 2023
* auto expand replicas (#539)

Signed-off-by: Ashish Agrawal <ashisagr@amazon.com>
(cherry picked from commit 1003936)

* Remove extra import

Signed-off-by: Ashish Agrawal <ashisagr@amazon.com>

---------

Signed-off-by: Ashish Agrawal <ashisagr@amazon.com>
Co-authored-by: Ashish Agrawal <ashish81394@gmail.com>
Co-authored-by: Ashish Agrawal <ashisagr@amazon.com>
lezzago added a commit that referenced this pull request Sep 11, 2023
* auto expand replicas (#539)

Signed-off-by: Ashish Agrawal <ashisagr@amazon.com>
(cherry picked from commit 1003936)

* Remove extra import

Signed-off-by: Ashish Agrawal <ashisagr@amazon.com>

---------

Signed-off-by: Ashish Agrawal <ashisagr@amazon.com>
Co-authored-by: Ashish Agrawal <ashish81394@gmail.com>
Co-authored-by: Ashish Agrawal <ashisagr@amazon.com>
lezzago added a commit that referenced this pull request Sep 11, 2023
* auto expand replicas (#539)

Signed-off-by: Ashish Agrawal <ashisagr@amazon.com>
(cherry picked from commit 1003936)

* Remove extra import

Signed-off-by: Ashish Agrawal <ashisagr@amazon.com>

---------

Signed-off-by: Ashish Agrawal <ashisagr@amazon.com>
Co-authored-by: Ashish Agrawal <ashish81394@gmail.com>
Co-authored-by: Ashish Agrawal <ashisagr@amazon.com>
sbcd90 pushed a commit that referenced this pull request Sep 13, 2023
* auto expand replicas (#539)

Signed-off-by: Ashish Agrawal <ashisagr@amazon.com>
riysaxen-amzn pushed a commit to riysaxen-amzn/security-analytics that referenced this pull request Feb 20, 2024
* Correlation engine ux (opensearch-project#524)

* wip

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

* completed rules page; added placeholder for findings flyout tabs

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

* reverted change to show empty table

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

* updated rule type

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

* updated create correlation rule page

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

* correlation page wip

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

* Correlation store and API services

Signed-off-by: Jovan Cvetkovic <jovanca.cvetkovic@gmail.com>

* Correlation store and API services

Signed-off-by: Jovan Cvetkovic <jovanca.cvetkovic@gmail.com>

* Correlation store and API services

Signed-off-by: Jovan Cvetkovic <jovanca.cvetkovic@gmail.com>

* Correlation store and API services

Signed-off-by: Jovan Cvetkovic <jovanca.cvetkovic@gmail.com>

* Correlation store and API services

Signed-off-by: Jovan Cvetkovic <jovanca.cvetkovic@gmail.com>

* updated correlations page

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

* updated store interfaces

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

* fixed correlation store

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

* added api for all correlations

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

* added filter support for correlations

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

* using apis; added validation

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

* Implemented logic to populate correlations tables data.

Signed-off-by: AWSHurneyt <hurneyt@amazon.com>

* restricted to AND

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

* log type clearable

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

* code cleanup

Signed-off-by: Jovan Cvetkovic <jovanca.cvetkovic@gmail.com>

* fixed API issue

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

* updated snapshots

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

* ux improvements

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

* code cleanup

Signed-off-by: Jovan Cvetkovic <jovanca.cvetkovic@gmail.com>

* removed redundant code

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

* removed unwanted param

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

* connected refresh

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

---------

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>
Signed-off-by: Jovan Cvetkovic <jovanca.cvetkovic@gmail.com>
Signed-off-by: AWSHurneyt <hurneyt@amazon.com>
Co-authored-by: Jovan Cvetkovic <jovanca.cvetkovic@gmail.com>
Co-authored-by: AWSHurneyt <hurneyt@amazon.com>
(cherry picked from commit f565a923c6bfec1b8a69128d21e5d823a50cb142)

* Removed duplicate import for EuiSpacer (opensearch-project#538) (opensearch-project#540)

* removed duplicate import



* updated snapshots



---------

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

* Pinned babel traverse and core (opensearch-project#539) (opensearch-project#544)

* pinned babel traverse and core



* removed cyclic dependency



* added types for vis



* refactored code



---------

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>

---------

Signed-off-by: Amardeepsingh Siglani <amardeep7194@gmail.com>
Co-authored-by: Amardeepsingh Siglani <amardeep7194@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants