[PR #631] [MERGED] fix(noodle): persist refresh failure backoff #1059

Closed
opened 2026-10-21 05:01:48 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Pasta-Devs/Marinara-Agents/pull/631
Author: @Gunterlie
Created: 8/27/2026
Status: ✅ Merged
Merged: 8/27/2026
Merged by: @Gunterlie

Base: staging ← Head: fix/noodle-durable-backoff


📝 Commits (1)

  • 24d2e98 fix(noodle): persist refresh failure backoff

📊 Changes

13 files changed (+334 additions, -218 deletions)

View changed files

➕ artifacts/noodle-1.2.15.zip (+0 -0)
📝 catalog/catalog.json (+8 -8)
📝 catalog/v2/catalog.json (+8 -8)
📝 catalog/v3/catalog.json (+8 -8)
📝 packages/noodle/client.js (+1 -1)
📝 packages/noodle/manifest.json (+5 -5)
📝 packages/noodle/server.mjs (+166 -166)
📝 packages/noodle/src/engine/packages/server/src/services/noodle/noodle-refresh-schedule.ts (+15 -8)
📝 packages/noodle/src/engine/packages/server/src/services/noodle/noodle-refresh-scheduler.service.ts (+2 -8)
📝 packages/noodle/src/engine/packages/server/src/services/storage/noodle.storage.ts (+1 -4)
📝 scripts/build-feature-packages.mjs (+1 -1)
📝 sources/engine/packages/server/src/services/noodle/noodle-data-cleanup.ts (+38 -1)
➕ tests/noodle-refresh-backoff.regression.ts (+81 -0)

📄 Description

Linked issue

Closes #628

Why this change

Noodle refresh polling retried provider failures at the normal poll cadence. The failure state was lost on restart, so a restarted Engine could resume requests at full frequency.

What changed

  • Persist consecutive refresh failure count and next retry time.
  • Apply capped exponential retry delays.
  • Preserve the retry state during schedule reconciliation and restart.
  • Clear failure state when refreshes are disabled or succeed.
  • Keep active scheduler work awaited during shutdown.
  • Bump Noodle to 1.2.15.
  • Rebuilt client.js, server.mjs, manifest, ZIP artifact, and v2/v3 catalog entries.

Validation

  • node scripts/test-catalog-lanes.mjs
  • node scripts/validate-catalog.mjs
  • npm run check
  • npx tsx tests/noodle-refresh-backoff.regression.ts
  • ZIP content inspection
  • git diff --check

Manual verification

  • Manually install or update Noodle through Marinara Engine.
  • Manually verify retry delays increase after repeated provider failures.
  • Manually verify retry state survives restart.
  • Manually verify successful refresh clears backoff.
  • Manually verify uninstall cleanup.

The repository check reports 68 existing lint warnings and no errors. Full combined regression execution remains blocked in this standalone checkout because package tests cannot resolve the Engine-owned @marinara-engine/shared package.

Summary by CodeRabbit

  • Bug Fixes

    • Improved Noodle refresh reliability by preserving failure state when schedules are regenerated.
    • Added exponential backoff for repeated refresh failures to reduce unnecessary retry attempts.
    • Ensured disabled schedules clear outdated failure information.
    • Successful refreshes now reset previous failure state correctly.
    • Scheduler shutdown now waits for active refresh work to finish.
  • Chores

    • Updated the Noodle package and catalog metadata to version 1.2.15.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/Pasta-Devs/Marinara-Agents/pull/631 **Author:** [@Gunterlie](https://github.com/Gunterlie) **Created:** 8/27/2026 **Status:** ✅ Merged **Merged:** 8/27/2026 **Merged by:** [@Gunterlie](https://github.com/Gunterlie) **Base:** `staging` ← **Head:** `fix/noodle-durable-backoff` --- ### 📝 Commits (1) - [`24d2e98`](https://github.com/Pasta-Devs/Marinara-Agents/commit/24d2e986e79ffb0efb282b6f33065c048ac4e9d3) fix(noodle): persist refresh failure backoff ### 📊 Changes **13 files changed** (+334 additions, -218 deletions) <details> <summary>View changed files</summary> ➕ `artifacts/noodle-1.2.15.zip` (+0 -0) 📝 `catalog/catalog.json` (+8 -8) 📝 `catalog/v2/catalog.json` (+8 -8) 📝 `catalog/v3/catalog.json` (+8 -8) 📝 `packages/noodle/client.js` (+1 -1) 📝 `packages/noodle/manifest.json` (+5 -5) 📝 `packages/noodle/server.mjs` (+166 -166) 📝 `packages/noodle/src/engine/packages/server/src/services/noodle/noodle-refresh-schedule.ts` (+15 -8) 📝 `packages/noodle/src/engine/packages/server/src/services/noodle/noodle-refresh-scheduler.service.ts` (+2 -8) 📝 `packages/noodle/src/engine/packages/server/src/services/storage/noodle.storage.ts` (+1 -4) 📝 `scripts/build-feature-packages.mjs` (+1 -1) 📝 `sources/engine/packages/server/src/services/noodle/noodle-data-cleanup.ts` (+38 -1) ➕ `tests/noodle-refresh-backoff.regression.ts` (+81 -0) </details> ### 📄 Description ## Linked issue Closes #628 ## Why this change Noodle refresh polling retried provider failures at the normal poll cadence. The failure state was lost on restart, so a restarted Engine could resume requests at full frequency. ## What changed - Persist consecutive refresh failure count and next retry time. - Apply capped exponential retry delays. - Preserve the retry state during schedule reconciliation and restart. - Clear failure state when refreshes are disabled or succeed. - Keep active scheduler work awaited during shutdown. - Bump Noodle to `1.2.15`. - Rebuilt `client.js`, `server.mjs`, manifest, ZIP artifact, and v2/v3 catalog entries. ## Validation - `node scripts/test-catalog-lanes.mjs` - `node scripts/validate-catalog.mjs` - `npm run check` - `npx tsx tests/noodle-refresh-backoff.regression.ts` - ZIP content inspection - `git diff --check` ## Manual verification - [ ] Manually install or update Noodle through Marinara Engine. - [ ] Manually verify retry delays increase after repeated provider failures. - [ ] Manually verify retry state survives restart. - [ ] Manually verify successful refresh clears backoff. - [ ] Manually verify uninstall cleanup. The repository check reports 68 existing lint warnings and no errors. Full combined regression execution remains blocked in this standalone checkout because package tests cannot resolve the Engine-owned `@marinara-engine/shared` package. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **Bug Fixes** - Improved Noodle refresh reliability by preserving failure state when schedules are regenerated. - Added exponential backoff for repeated refresh failures to reduce unnecessary retry attempts. - Ensured disabled schedules clear outdated failure information. - Successful refreshes now reset previous failure state correctly. - Scheduler shutdown now waits for active refresh work to finish. - **Chores** - Updated the Noodle package and catalog metadata to version 1.2.15. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-21 05:01:48 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Pasta-Devs/Marinara-Agents#1059
No description provided.