Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Scale up from single unit fails if leader gets removed before new unit settle #308

Open
paulomach opened this issue Aug 25, 2023 · 2 comments
Labels
bug Something isn't working

Comments

@paulomach
Copy link
Contributor

Steps to reproduce:

  1. Deploy 1 unit of mysql
  2. Relate mysql and wordpress-k8s charm together
  3. Add another unit for mysql charm and delete the leader unit.
  4. Leader is elected on the mysql charm as the newly created unit without it being fully initialized
  5. WordPress tries to connect to uninitialized unit and fails
@paulomach paulomach added the bug Something isn't working label Aug 25, 2023
@github-actions
Copy link
Contributor

@paulomach
Copy link
Contributor Author

Problem assumption:

While the joining unit has not yet joined the mysql cluster (data sync not finished), the leader unit is removed, the joining unit fails to become active with the data/users created for a previously existing relations.

Potential solution:

For a 2 unit application, when one of them get removed, ensure both are fully initialized before executing removal (by ways of defer or holding execution).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant