Repository navigation
fix: retry transient no-response network errors instead of aborting - #5773
maheshkutty merged 6 commits into
Conversation
|
👋 I'm rudder-devbox. I opened this PR from task Mention |
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #5773 +/- ##
========================================
Coverage 92.44% 92.45%
========================================
Files 741 741
Lines 41121 41172 +51
Branches 9676 9691 +15
========================================
+ Hits 38015 38065 +50
- Misses 2845 2846 +1
Partials 261 261 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Co-Authored-By: Claude Opus 5.5 <[email protected]> 🔒 Scanned for secrets using gitleaks 8.30.1
Co-Authored-By: Claude Opus 5.5 <[email protected]> 🔒 Scanned for secrets using gitleaks 8.30.1
Co-Authored-By: Claude Opus 5.5 <[email protected]> 🔒 Scanned for secrets using gitleaks 8.30.1
|
Knowledge distillation completed |
|
Knowledge distillation completed |
|



What are the changes introduced in this PR?
Classify EMFILE, ENFILE, EPIPE, EHOSTUNREACH, ENETUNREACH and EADDRNOTAVAIL as retryable 500s when a request gets no HTTP response. Gladly's customer lookup branched on this status, so it now fails a lookup error with its own status instead of building a create or a malformed update. Add regression tests for the shared mapping, proxy delivery, and Gladly; update HubSpot's EPIPE expectation. Add guidance on lookup and transport-failure handling to the batching-framework skills.
Errors now retried (5xx)
Reference: libuv error constants for the system codes (Node.js reports them as
err.codewithout theUV_prefix).EMFILE: the transformer process ran out of file descriptors.ENFILE: the host ran out of file descriptors system-wide.EPIPE: the transformer wrote to a connection the destination had already closed, e.g. a stale keep-alive socket.EHOSTUNREACH: there is no network route to the destination host.ENETUNREACH: there is no route to the destination's network.EADDRNOTAVAIL: no local address or port is free for a new connection (ephemeral port exhaustion).ENETDOWNandERR_SOCKET_CONNECTION_TIMEOUTremain on the unknown-code 400 fallback; neither was reproducible through the transformer HTTP client during review.What is the related Linear task?
Resolves INT-7348
Please explain the objectives of your changes below
Preserve existing permanent-error classification and Gladly's established create-on-400 and successful-update behavior while retrying transient failures.
Any changes to existing capabilities/behaviour, mention the reason & what are the changes ?
The six no-response errors above now return 500 instead of 400. Gladly lookup failures other than status 400 now return a network error before customer creation or update.
Any new dependencies introduced with this change?
N/A
Any new generic utility introduced or modified. Please explain the changes.
The existing shared Node-system-error status map was extended; no new utility was introduced.
Any technical or performance related pointers to consider with the change?
No new network calls. Gladly secret-path regeneration confirmed
headers.Authorizationis unchanged; the destination-only generated map was not committed.Validation
npm run lint,npm run build:ci, andnpm run build:testpassed.npm test -- --testPathPattern='(networkUtils|delivery|lookup)' --runInBand --no-coverage --silent: 21 suites, 460 tests passed.npm run test:ts -- component --destination=gladly --no-coverage --runInBand --silent: 14 tests passed.git diff --checkpassed. The controller suite also passed after the final mock-cleanup edit.mini ps --services transformer rudder-servershowed no running services, and the transformer sha-pinned image build cannot run this source change in the sandbox.Live mini verification was skipped because the transformer source build uses a sha-pinned base that is not source-verifiable in this sandbox. The targeted unit and component tests passed.
Developer checklist
.claude/skills/batching-framework*/SKILL.md.Reviewer checklist