Skip to content

ci(elasticsearch): split slow module tests - #12111

Open
itsCodeTide wants to merge 1 commit into
testcontainers:mainfrom
itsCodeTide:fix/elasticsearch-module-ci
Open

itsCodeTide wants to merge 1 commit into
testcontainers:mainfrom
itsCodeTide:fix/elasticsearch-module-ci

Conversation

@itsCodeTide

@itsCodeTide itsCodeTide commented Oct 14, 2026 •

Copy link
Copy Markdown

Why?

:testcontainers-elasticsearch:check runs two container-heavy test classes in one CI job, making the Elasticsearch module a long-running step in the pipeline.

What does this PR do?

  • Runs the module checks and each Elasticsearch integration test class as separate CI matrix entries.
  • Moves the default heap and cluster health assertions into the existing latest-version smoke test, preserving those checks while removing one redundant Elasticsearch startup.

Fixes #12070

Verification

  • :testcontainers-elasticsearch:compileTestJava passed.
  • :testcontainers-elasticsearch:checkstyleTest passed.
  • :testcontainers-elasticsearch:spotlessJavaCheck passed.
  • Gradle dry runs accepted both class filters and the static-check entry.
  • Container tests were not run locally because Docker is unavailable. CI will provide the before/after job timing.

Summary by CodeRabbit

  • Tests
    • Expanded automated coverage for Elasticsearch container startup, including cluster health and default memory settings.
    • CI now runs the Elasticsearch and Kibana container tests as separate tasks.

@itsCodeTide
itsCodeTide requested a review from a team as a code owner October 14, 2026 18:13
@github-actions github-actions Bot added modules/elasticsearch github_actions Pull requests that update Github_actions code labels Oct 14, 2026
@coderabbitai

coderabbitai Bot commented Oct 14, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: f8539899-f766-4605-bf61-e7f74cb72acc
📥 Commits

Reviewing files that changed from the base of the PR and between 9bb3c2d and 34cdd09.

📒 Files selected for processing: 2
  • .github/workflows/ci.yml
  • modules/elasticsearch/src/test/java/org/testcontainers/elasticsearch/ElasticsearchContainerTest.java

Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 7 remain after this review.

📝 Walkthrough

The Elasticsearch test suite combines latest-image health and heap checks with its TLS and password test. The CI workflow schedules the Elasticsearch and Kibana test classes as separate matrix tasks.

Changes: Elasticsearch CI test split

Layer / File(s) Summary
Consolidate latest-image checks
modules/elasticsearch/src/test/java/org/testcontainers/elasticsearch/ElasticsearchContainerTest.java
latestStartsWithTlsAndPassword now checks cluster health and the default 2 GiB heap size. The separate health and heap tests were removed.
Split Elasticsearch CI tasks
.github/workflows/ci.yml
The Elasticsearch check task excludes its tests, which are scheduled as separate ElasticsearchContainerTest and KibanaContainerTest matrix tasks.

Priority: ➖ Normal

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Other

Suggested reviewers: eddumelendez

Merge Risk: ⚪ Minimal · up to 34cdd

The latest-image checks remain covered, and CI schedules both test classes separately while retaining static checks. No material merge-blocking risk is evident; normal CI execution remains the final validation.

Pre-merge checks: Passed 4 · Failed 1

Failed Failed checks: 1 warning

Check name Status Explanation Resolution
Docstring Coverage Warning Docstring coverage is 25.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 4 functions across 1 files. (1 skipped: 1… Write docstrings for the functions missing them to satisfy the coverage threshold.
Passed Passed checks: 4 passed
Check name Status Explanation
Description check Passed The description explains the CI bottleneck, lists the changes, references issue #12070, and documents verification results and the Docker limitation.
Title check Passed The title clearly and concisely identifies the main change: splitting slow Elasticsearch module tests in CI.
Linked Issues check Passed Issue [#12070] requires splitting the Elasticsearch module checks into separate CI jobs without removing coverage. .github/workflows/ci.yml expands the Elasticsearch check into three matrix tasks: c…
Out of Scope Changes check Passed The reported changes are limited to the Elasticsearch CI matrix and the related test consolidation. The CI change implements [#12070]'s split proposal. The test change retains existing assertions whil…
Full details: Docstring Coverage

Explanation

Docstring coverage is 25.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 4 functions across 1 files. (1 skipped: 1 unsupported.)

  • Fix all pre-merge checks with AI
✨ Finishing Touches: 💡 1
🛠️ Fix failing CI checks: 💡
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

github_actions Pull requests that update Github_actions code modules/elasticsearch

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Enhancement]: Speed up elasticsearch module CI (22 min vs ~1 min for other modules)

1 participant