-
Notifications
You must be signed in to change notification settings - Fork 1
fix(ci): make memory-gate visible, fail loudly, stop starving roles_calculation #170
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
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -7,29 +7,34 @@ dependency: | |
| driver: | ||
| name: default | ||
| platforms: | ||
| # 2 GB per container: the scenario runs elasticsearch_heap: 1 (= 1 GB) | ||
| # and only exercises the role-count-calculation code path, not any | ||
| # ingest workload. The default 4 GB was making the 16 GB total block | ||
| # the memory-capacity gate under peak concurrency and starve the | ||
| # scenario until the 45-min workflow timeout cancelled it. | ||
| - name: "es-calc1-${MOLECULE_DISTRO:-debian12}-r${ELASTIC_RELEASE:-9}${MOLECULE_RUN_SUFFIX}" | ||
| groups: | ||
| - elasticsearch | ||
| distro: "${MOLECULE_DISTRO:-debian12}" | ||
| memory_mb: 4096 | ||
| memory_mb: 2048 | ||
| - name: "es-calc2-${MOLECULE_DISTRO:-debian12}-r${ELASTIC_RELEASE:-9}${MOLECULE_RUN_SUFFIX}" | ||
| groups: | ||
| - elasticsearch | ||
| distro: "${MOLECULE_DISTRO:-debian12}" | ||
| memory_mb: 4096 | ||
| memory_mb: 2048 | ||
| - name: "es-calc3-${MOLECULE_DISTRO:-debian12}-r${ELASTIC_RELEASE:-9}${MOLECULE_RUN_SUFFIX}" | ||
| groups: | ||
| - elasticsearch | ||
| distro: "${MOLECULE_DISTRO:-debian12}" | ||
| memory_mb: 4096 | ||
| memory_mb: 2048 | ||
| # Separate single-node "monitoring" cluster, run in a second play against | ||
| # this group to catch the regression from #143 where group_by accumulated | ||
| # elasticsearch_role_master across plays. | ||
| - name: "es-calc-mon-${MOLECULE_DISTRO:-debian12}-r${ELASTIC_RELEASE:-9}${MOLECULE_RUN_SUFFIX}" | ||
| groups: | ||
| - elasticsearch_mon | ||
| distro: "${MOLECULE_DISTRO:-debian12}" | ||
| memory_mb: 4096 | ||
| memory_mb: 2048 | ||
|
Comment on lines
+19
to
+37
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🚀 Performance & Scalability | 🟠 Major | ⚡ Quick win Synchronize the capacity reservation with the new total. These four platforms now request Update the reservation to 🤖 Prompt for AI Agents |
||
| provisioner: | ||
| name: ansible | ||
| env: | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -126,7 +126,14 @@ | |
| REMOTE_SCRIPT | ||
| changed_when: true | ||
| register: _launch_result | ||
| retries: 360 | ||
| # 30 retries × 30s = 15 min. Deliberately shorter than the workflow | ||
| # timeout (45 min for the standard molecule.yml call, 120 min for | ||
| # full_stack) so the task fails loudly with the last "No capacity: | ||
| # …" stdout instead of being silently cancelled by the workflow | ||
| # timeout — that made the queue-starvation cases very hard to | ||
| # diagnose (see PR investigating the elasticsearch_roles_calculation | ||
| # / elasticstack_default post-outage hangs). | ||
| retries: 30 | ||
| delay: 30 | ||
| until: _launch_result.rc == 0 | ||
|
Comment on lines
+129
to
138
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🩺 Stability & Availability | 🟠 Major | ⚡ Quick win 🧩 Analysis chain🏁 Script executed: #!/bin/bash
set -euo pipefail
echo "Files matching molecule/shared/create.yml:"
git ls-files | grep -Fx 'molecule/shared/create.yml' || true
echo
echo "Context around create.yml lines 60-150:"
if [ -f molecule/shared/create.yml ]; then
nl -ba molecule/shared/create.yml | sed -n '60,160p'
fi
echo
echo "Search workflow timeout mentions:"
rg -n "45 min|120 min|timeout|full_stack|molecule.yml|retry|delay|flock -x -w 60|_launch_result" molecule .github 2>/dev/null || trueRepository: Oddly/elasticstack Length of output: 308 🏁 Script executed: #!/bin/bash
set -euo pipefail
echo "Context around molecule/shared/create.yml lines 60-150:"
awk '{printf "%6d\t%s\n", NR, $0}' molecule/shared/create.yml | sed -n '60,150p'
echo
echo "Context around launch/flock tasks and retries/delay:"
awk '{printf "%6d\t%s\n", NR, $0}' molecule/shared/create.yml | sed -n '1,180p'
echo
echo "Search workflow timeout mentions:"
rg -n "45 min|120 min|timeout|full_stack|molecule.yml|retry|delay|flock -x -w 60|_launch_result|molecule/shared/create.yml" molecule .github 2>/dev/null || trueRepository: Oddly/elasticstack Length of output: 27420 Bound the retry window by elapsed time.
🤖 Prompt for AI Agents |
||
|
|
||
|
|
||
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.
📐 Maintainability & Code Quality | 🟠 Major | 🏗️ Heavy lift
Use the reusable Molecule workflow for this timeout.
This job runs Molecule directly and sets
timeout-minuteslocally..github/workflows/molecule.ymlalready exposes atimeoutinput and applies it to the reusable job. Pass180through that workflow instead of maintaining a second Molecule implementation. This keeps runner, environment, cleanup, matrix, and timeout behavior under one workflow contract.As per path instructions, Molecule test workflows should use the reusable
molecule.ymlworkflow.🤖 Prompt for AI Agents
Source: Path instructions