Closed reneradoi closed 3 weeks ago
Thanks for reporting, we will tackle it in this cycle, though cannot commit exactly when as of now.
@alithethird Can you confirm this is fixed and close the issue, please?
I can confirm this is fixed and closing.
Bug Description
Hi Team!
In
redis-k8s-operator
we run an integration test deploying and relatingdiscourse-k8s
to Redis. On some CI runs I experienced issues with the discourse charm because it can't write to the Redis database.The reason for this is that the
redis-client
tries to connect to the first advertised host it can find in the relation data (here). But since a bug was fixed onredis-k8s-operator
side, the relation data now includes all hosts there, not just the one of the Sentinel Master anymore. This was fixed with this PR, which means you now have to consider all advertised hosts, not just anyone anymore.One more notice: This behaviour only happens if the Sentinel Master is not the unit
/0
. If, by accident,redis-k8s/0
is the Sentinel Master, or in setups with just one Redis unit, the integration works fine.To Reproduce
juju deploy redis-k8s --channel edge -n 3
juju deploy postgresql-k8s --channel 14/stable
juju deploy discourse-k8s --channel latest/stable
juju integrate postgresql-k8s:database discourse-k8s
juju integrate redis-k8s discourse-k8s
Environment
see above.
Example for failed CI run: https://github.com/canonical/redis-k8s-operator/actions/runs/9760370147/job/26939124902
Relevant log output