Skip to content

Conversation

@barshaul
Copy link
Contributor

@barshaul barshaul commented Dec 29, 2025

Description of change

Circular MOVED responses were incorrectly treated as failover events, causing the
primary node to be demoted and leaving shards with replicas only.

This can occur in DNS-based environments where a MOVED response intentionally
points back to the same address (e.g., MOVED + disconnect to force DNS re-resolution).

This change detects circular MOVED redirects and avoids updating the slot map
when the redirected node is already the shard primary.

Pull Request check-list

Please make sure to review and check all of these items:

  • Do tests and lints pass with this change?
  • Do the CI tests pass with this change (enable it first in your forked repo and wait for the github action build to finish)?
  • Is the new or changed code fully tested?
  • Is a documentation update included (if this change modifies existing APIs, or introduces new ones)?
  • Is there an example added to the examples folder (if applicable)?

@jit-ci
Copy link

jit-ci bot commented Dec 29, 2025

Hi, I’m Jit, a friendly security platform designed to help developers build secure applications from day zero with an MVS (Minimal viable security) mindset.

In case there are security findings, they will be communicated to you as a comment inside the PR.

Hope you’ll enjoy using Jit.

Questions? Comments? Want to learn more? Get in touch with us.

… the redirected node is already the shard primary.
@petyaslavova
Copy link
Collaborator

Hi @barshaul, thank you for your contribution. We will review it soon.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants