Skip to content

Conversation

@indiebrain
Copy link

Boostrapping fails if the bootstrapNode and RF's redis port are different.

The operator uses the bootstrapNode's port when trying to run SLAVEOF on the RF pods and fails to connect:

Example RF config:

  bootstrapNode:
    enabled: true
    host: redis-primary-host.io
    port: "36379"
...
  redis:
    port: 6679
...

Example failure logs:

time="2025-06-05T19:08:29Z" level=info msg="Making pod rfr-redis-0 slave of redis-primary-host.io:36379" namespace=redis-test redisfailover=redis service=redis.healer src="checker.go:261"
time="2025-06-05T19:08:29Z" level=error msg="error on object processing: dial tcp 10.244.2.7:36379: connect: connection refused" controller-id=redisfailover object-key=redis-test/redis operator=redisfailover service=kooper.controller src="controller.go:282"

This alters MakeSlaveOfWithPort to allow the caller to speficy different ports for the primary and replica redis instances. Additonally, SetExternalMasterOnAll is alertered to pass along the boostrapNode's port as well as the RF resources's port - which can be different.

@indiebrain indiebrain self-assigned this Jun 5, 2025
@indiebrain indiebrain marked this pull request as ready for review June 5, 2025 19:35
@indiebrain indiebrain requested a review from a team June 5, 2025 19:35
@indiebrain indiebrain requested a review from a team as a code owner June 6, 2025 14:06
@indiebrain indiebrain requested a review from c-gerke June 9, 2025 12:30
@indiebrain indiebrain merged commit 62678ef into master Jun 9, 2025
12 checks passed
@indiebrain indiebrain deleted the 20250605--bootstrap--allow-master-with-different-port branch June 9, 2025 12:30
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.

3 participants