pingcap / pingcap/tidb-operator

It should be forbidden to switch between mutiple operators if they use different kind of StatefulSet.

Open
#3,693 2 comments 0 reactions 1 assignee View on GitHub

@cvvz is already working on this.

Since Jan 8, 2021.

area/controller
Dominant language
Go
Stars
1.3k
Forks
540
Avg merge
3d 2h
Merged PRs (30d)
18

Description

Bug Report

What did you do?

  1. Deploy mutiple operators, some with AdvancedStatefulset=true, which means use AdvancedStatefulset, some use Kubernetes built-in Statefulset.
  2. Switch between these operators by changing the labels of TidbCluster.

What did you expect to see?
Because different operators use different Statefulsets, it should not be able to switch between them.

What did you see instead?
When tidb-controller-manager taked over TidbCluster after labels are matched with label selector, it will create AdvancedStatefulset or built-in StatefulSet according to the feature , which may lead to two different kind of Statefulset exist at the same time, but the new Statefulset can't create any Pod, because Pod names are being used.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.