Skip to content

Revert "Add integ test for simulating node join left event when data …#20674

Merged
andrross merged 1 commit intoopensearch-project:mainfrom
andrross:revert-nodejoinleftit
Feb 19, 2026
Merged

Revert "Add integ test for simulating node join left event when data …#20674
andrross merged 1 commit intoopensearch-project:mainfrom
andrross:revert-nodejoinleftit

Conversation

@andrross
Copy link
Member

@andrross andrross commented Feb 18, 2026

…node..."

This reverts the following commits:

These tests have been very flaky since they were introduced in PR #19907

image

@SwethaGuptha @shwetathareja It would be great to fix these, but we have been unsuccessful in the past couple months (see #20382). Unless we have a quick fix then I think a revert is better in the short term.

Check List

  • Functionality includes testing.

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.

…node..."

This reverts the following commits:
- 5e80506
- 62eed1e

Signed-off-by: Andrew Ross <andrross@amazon.com>
@andrross andrross requested a review from a team as a code owner February 18, 2026 22:54
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Feb 18, 2026

📝 Walkthrough

Walkthrough

This PR removes test infrastructure and methods from the cluster coordination test suite, including custom listener plugins, lag-simulation test scenarios, and associated test utility methods. The changes affect the test scaffolding in NodeJoinLeftIT, the RequiresTestIndexStoreListener annotation, and public API methods in TestLogsAppender.

Changes

Cohort / File(s) Summary
Test Class Cleanup
server/src/internalClusterTest/java/org/opensearch/cluster/coordination/NodeJoinLeftIT.java
Removed TestIndexStoreListenerPlugin and TestIndexStoreListener inner classes, eliminated publication lag-related test methods (testClusterStabilityWhenClusterStatePublicationLagsOnShardCleanup, testClusterStabilityWhenClusterStatePublicationLagsWithLongRunningListenerOnApplierThread), removed supporting helper methods (additionalSetupForLagDuringDataMigration, validateNodeDropDueToPublicationLag, validateClusterRecovery, createDelayListener), simplified node startup logic, and replaced dynamic message list initialization with static Arrays.asList.
Annotation Removal
server/src/internalClusterTest/java/org/opensearch/cluster/coordination/RequiresTestIndexStoreListener.java
Removed the RequiresTestIndexStoreListener annotation interface entirely.
Test Utility API Changes
test/framework/src/main/java/org/opensearch/test/TestLogsAppender.java
Removed public methods addMessagesToCapture(Set\<String\>) and addMessageToCapture(String), eliminating indirect pathways for message addition to capture list.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

Possibly related PRs

Suggested labels

flaky-test

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately reflects the main change—reverting an integration test PR related to node join/left events.
Description check ✅ Passed The pull request description adequately explains the purpose (reverting flaky tests), references specific commits, provides justification with a monitoring chart, and completes the required checklist items.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

🧹 Nitpick comments (1)
server/src/internalClusterTest/java/org/opensearch/cluster/coordination/NodeJoinLeftIT.java (1)

75-76: Non-standard javadoc formatting.

The javadoc comment is missing the conventional * prefix on continuation lines. While syntactically valid, standard javadoc format uses asterisks for consistency and readability.

Suggested fix
 /**
- Check https://github.com/opensearch-project/OpenSearch/issues/4874 and
- https://github.com/opensearch-project/OpenSearch/pull/15521 for context
+ * Check https://github.com/opensearch-project/OpenSearch/issues/4874 and
+ * https://github.com/opensearch-project/OpenSearch/pull/15521 for context
  */
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@server/src/internalClusterTest/java/org/opensearch/cluster/coordination/NodeJoinLeftIT.java`
around lines 75 - 76, The class-level Javadoc for NodeJoinLeftIT uses
continuation lines without the conventional " * " prefix; update the Javadoc
above the NodeJoinLeftIT class (or the affected Javadoc block) so each
continuation line begins with " * " (i.e., standard Javadoc block form /**\n *
First line\n * Check https://... and\n * https://... for context\n */) to match
project style and improve readability.
📜 Review details

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 628aa3d and f7963f6.

📒 Files selected for processing (3)
  • server/src/internalClusterTest/java/org/opensearch/cluster/coordination/NodeJoinLeftIT.java
  • server/src/internalClusterTest/java/org/opensearch/cluster/coordination/RequiresTestIndexStoreListener.java
  • test/framework/src/main/java/org/opensearch/test/TestLogsAppender.java
💤 Files with no reviewable changes (2)
  • server/src/internalClusterTest/java/org/opensearch/cluster/coordination/RequiresTestIndexStoreListener.java
  • test/framework/src/main/java/org/opensearch/test/TestLogsAppender.java
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (21)
  • GitHub Check: gradle-check
  • GitHub Check: Analyze (java)
  • GitHub Check: assemble (21, ubuntu-latest)
  • GitHub Check: assemble (21, ubuntu-24.04-arm)
  • GitHub Check: assemble (25, ubuntu-latest)
  • GitHub Check: assemble (21, windows-latest)
  • GitHub Check: assemble (25, ubuntu-24.04-arm)
  • GitHub Check: assemble (25, windows-latest)
  • GitHub Check: precommit (25, macos-15)
  • GitHub Check: precommit (21, ubuntu-24.04-arm)
  • GitHub Check: precommit (21, macos-15-intel)
  • GitHub Check: precommit (21, ubuntu-latest)
  • GitHub Check: precommit (25, ubuntu-latest)
  • GitHub Check: precommit (21, windows-latest)
  • GitHub Check: precommit (25, macos-15-intel)
  • GitHub Check: precommit (21, macos-15)
  • GitHub Check: precommit (25, ubuntu-24.04-arm)
  • GitHub Check: precommit (21, windows-2025, true)
  • GitHub Check: precommit (25, windows-latest)
  • GitHub Check: detect-breaking-change
  • GitHub Check: Mend Security Check
🔇 Additional comments (4)
server/src/internalClusterTest/java/org/opensearch/cluster/coordination/NodeJoinLeftIT.java (4)

88-95: LGTM!

The removal of TestIndexStoreListenerPlugin as part of this revert is appropriate. The remaining plugins are standard test infrastructure for transport mocking and index store testing.


109-111: LGTM!

The simplified static initialization using Arrays.asList is appropriate here. The list is only used to configure the log appender at initialization.


119-126: LGTM!

Converting nodeSettings to a local final variable is appropriate as it's only used within setUp(). This reduces class-level state.

Note: Lines 121 and 125 both configure CLUSTER_NODE_RECONNECT_INTERVAL_SETTING (the second value 100ms overrides 10s). This appears to be pre-existing code, so it's outside the scope of this revert.


127-128: LGTM!

The change from startClusterManagerOnlyNode to startNode restores the original test configuration as part of this revert. The first node will now have both cluster-manager and data node roles, which aligns with the simplified test setup after removing the flaky test infrastructure.

🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Nitpick comments:
In
`@server/src/internalClusterTest/java/org/opensearch/cluster/coordination/NodeJoinLeftIT.java`:
- Around line 75-76: The class-level Javadoc for NodeJoinLeftIT uses
continuation lines without the conventional " * " prefix; update the Javadoc
above the NodeJoinLeftIT class (or the affected Javadoc block) so each
continuation line begins with " * " (i.e., standard Javadoc block form /**\n *
First line\n * Check https://... and\n * https://... for context\n */) to match
project style and improve readability.

@github-actions
Copy link
Contributor

✅ Gradle check result for f7963f6: SUCCESS

@codecov
Copy link

codecov bot commented Feb 19, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 73.27%. Comparing base (db0a16d) to head (f7963f6).
⚠️ Report is 10 commits behind head on main.

Additional details and impacted files
@@             Coverage Diff              @@
##               main   #20674      +/-   ##
============================================
+ Coverage     73.19%   73.27%   +0.07%     
- Complexity    71924    72025     +101     
============================================
  Files          5781     5781              
  Lines        329292   329396     +104     
  Branches      47514    47525      +11     
============================================
+ Hits         241026   241365     +339     
+ Misses        68925    68624     -301     
- Partials      19341    19407      +66     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@andrross andrross merged commit 718d36a into opensearch-project:main Feb 19, 2026
41 checks passed
@andrross andrross deleted the revert-nodejoinleftit branch February 19, 2026 17:40
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.

2 participants

Comments