Skip to content

Add workflow for v0.3.0#429

Open
ahrtr wants to merge 1 commit into
mainfrom
20260715_workflow_0.3.0
Open

Add workflow for v0.3.0#429
ahrtr wants to merge 1 commit into
mainfrom
20260715_workflow_0.3.0

Conversation

@ahrtr

@ahrtr ahrtr commented Jul 15, 2026

Copy link
Copy Markdown
Member

cc @nwnt @silentred

I will present this workflow in our next community meeting.

Some details (e.g. PV/PVC stuff) still need clarification. But this is just a high level workflow, it should be already good enough for now.

@kubernetes-prow

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: ahrtr

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@nwnt

nwnt commented Jul 21, 2026

Copy link
Copy Markdown
Member

Just to put the comments here for the discussion during the meeting:

  1. I think the reconciliation loop doesn't need to actively correct the ordinal, and instead should only be correcting when there's a need to replace the pod. The 'lazy' approach should in theory reduce the potential instability from replacing an existing pod, which might or might not be a leader.
  2. The update config should be perhaps be done earlier than later (i.e. fix a failed member or create an additional pod when the expected count is higher). By doing so, I think it introduces less disruption by not having to go through pod creation and then later kill them because they're mismatched with the current content of EtcdCluster.
  3. When the leader pod is about to be killed, we should also move the leader to the pod with the least possible ordinal as the higher ones are deemed to be killed first unless they are a leader:
    • In a 5 replica cluster, if the current leader is 3, then 4, 2, 1, 0 are killed and recreated first. The leadership would be transferred from 3 to 0, as 4 will be killed first and before 3 during a scale-in.
    • If the current leader is 0, it would still be killed last, but the leadership should then be moved to 1 and the operator will leave it there.

<h>410</h>
</coordinates>
<panel_attributes>lt=.
Health check &amp; Fix failed member/POD

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"failed member/POD" means members that cannot pass health check?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Basically yes

<w>230</w>
<h>40</h>
</coordinates>
<panel_attributes>try to fix one member/POD</panel_attributes>

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixing workflow seems to be a heavy work. It depends on cases, quorum hold vs not hold, data corrupted vs not corrupted.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, we need to breakdown this when we work on the v0.3.0 roadmap tasks.

<h>510</h>
</coordinates>
<panel_attributes>lt=.
Exception handling

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Currently, it is more like "ensuring replicas number". What is the difference with "Scale in & out" section?

Should we wait the pod, created in the previous loop and in the starting process, to be Ready and started in etcd cluster Members API?

Signed-off-by: Benjamin Wang <benjamin.ahrtr@gmail.com>
@ahrtr
ahrtr force-pushed the 20260715_workflow_0.3.0 branch from 6877c9e to 4a67d7a Compare July 21, 2026 16:03
@nwnt

nwnt commented Jul 21, 2026

Copy link
Copy Markdown
Member

Comments from the community meeting:

  1. Learner promotion maybe should be done at the fix failed member stage to avoid deadlocks from having multiple learners.
  2. During exception handling that we need to remove pods, if the pod we're about to remove is the leader, we need to move it to other member first.
  3. If the config of etcd cluster has been updated, the pod with highest ordinal will be replaced first and so on.

@silentred

Copy link
Copy Markdown
Contributor
  1. Learner promotion maybe should be done at the fix failed member stage to avoid deadlocks from having multiple learners.

A similar case in the meeting:
For a misconfigured 3-node cluster with one failed member pod, should we choose to fix the member or replace the old pod (user has updated EtcdCluster CR) first? New member may not be able join the cluster, due to the old wrong Spec.

@ahrtr

ahrtr commented Jul 22, 2026

Copy link
Copy Markdown
Member Author

Comments from the community meeting:

  1. Learner promotion maybe should be done at the fix failed member stage to avoid deadlocks from having multiple learners.
  2. During exception handling that we need to remove pods, if the pod we're about to remove is the leader, we need to move it to other member first.
  3. If the config of etcd cluster has been updated, the pod with highest ordinal will be replaced first and so on.

Updated.

  1. Learner promotion maybe should be done at the fix failed member stage to avoid deadlocks from having multiple learners.

A similar case in the meeting: For a misconfigured 3-node cluster with one failed member pod, should we choose to fix the member or replace the old pod (user has updated EtcdCluster CR) first? New member may not be able join the cluster, due to the old wrong Spec.

Yes

@nwnt @silentred this is just a high level workflow. There are two key points:

  • We always try to fix any problems/issues first, before performing any normal operation.
  • We need to ensure the workflow is idempotent

If there is no any objection, let's merge this for now. We can discuss more details separately when we work on the refactoring work and v0.3.0 roadmap tasks

@ahrtr

ahrtr commented Jul 22, 2026

Copy link
Copy Markdown
Member Author

cc @ArkaSaha30 @nwnt @silentred @ivanvc PTAL

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants