Skip to content

Handle Redis connection issues gracefully by falling back to other cache strategies#41699

Closed
lociii wants to merge 1 commit intorenovatebot:mainfrom
lociii:redis-connection-timeout
Closed

Handle Redis connection issues gracefully by falling back to other cache strategies#41699
lociii wants to merge 1 commit intorenovatebot:mainfrom
lociii:redis-connection-timeout

Conversation

@lociii
Copy link

@lociii lociii commented Mar 5, 2026

Changes

Catch Redis connection timeouts and gracefully log them falling back to the next caching strategy.
If a cache is not accessible, it should behave as if the cache had a miss, not as a fatal error.

DEBUG: Redis cache init
FATAL: Unknown error
       "err": {
         "message": "Connection timeout",
         "stack": "Error: Connection timeout\n    at Socket.onTimeout (/usr/local/renovate/node_modules/.pnpm/@redis+client@5.11.0/node_modules/@redis/client/lib/client/socket.ts:274:40)\n    at Object.onceWrapper (node:events:622:28)\n    at Socket.emit (node:events:508:28)\n    at Socket.emit (node:domain:489:12)\n    at Socket._onTimeout (node:net:604:8)\n    at listOnTimeout (node:internal/timers:605:17)\n    at processTimers (node:internal/timers:541:7)"
       }
 INFO: Renovate is exiting with a non-zero code due to the following logged errors
       "loggerErrors": [
         {
           "name": "renovate",
           "level": 60,
           "logContext": "503e5b3c-cd2a-42b4-9d94-81900d7e0cca",
           "err": {
             "message": "Connection timeout",
             "stack": "Error: Connection timeout\n    at Socket.onTimeout (/usr/local/renovate/node_modules/.pnpm/@redis+client@5.11.0/node_modules/@redis/client/lib/client/socket.ts:274:40)\n    at Object.onceWrapper (node:events:622:28)\n    at Socket.emit (node:events:508:28)\n    at Socket.emit (node:domain:489:12)\n    at Socket._onTimeout (node:net:604:8)\n    at listOnTimeout (node:internal/timers:605:17)\n    at processTimers (node:internal/timers:541:7)"
           },
           "msg": "Unknown error"
         }
       ]

Context

Please select one of the following:

  • This closes an existing Issue
  • This doesn't close an Issue, but I accept the risk that this PR may be closed if maintainers disagree with its opening or implementation

AI assistance disclosure

Did you use AI tools to create any part of this pull request?

Please select one option and, if yes, briefly describe how AI was used (e.g., code, tests, docs) and which tool(s) you used.

  • No — I did not use AI for this contribution.
  • Yes — minimal assistance (e.g., IDE autocomplete, small code completions, grammar fixes).
  • Yes — substantive assistance (AI-generated non‑trivial portions of code, tests, or documentation).
  • Yes — other (please describe):

Documentation (please check one with an [x])

  • I have updated the documentation, or
  • No documentation update is required

How I've tested my work (please select one)

I have verified these changes via:

  • Code inspection only, or
  • Newly added/modified unit tests, or
  • No unit tests, but ran on a real repository, or
  • Both unit tests + ran on a real repository

@github-actions github-actions bot requested a review from viceice March 5, 2026 14:46
@viceice viceice added the auto:discussion-first This PR needs to be preceded by a GitHub Discussion label Mar 5, 2026
@github-actions
Copy link
Contributor

github-actions bot commented Mar 5, 2026

Please create a GitHub Discussion before continuing with this PR.

Thank you for your PR, but we need to discuss the requirements and implementation first.

The maintainers believe that there is a lack of - or misalignment of - requirements about this PR. We need to discuss the requirements and implementation first so that you don't write code that won't be merged.

This PR will be closed for now to avoid confusion, but you can reopen it after the discussion has been resolved.

Thanks, the Renovate team

@github-actions github-actions bot closed this Mar 5, 2026
@viceice viceice removed their request for review March 5, 2026 18:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

auto:discussion-first This PR needs to be preceded by a GitHub Discussion

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants