Skip to content

/ready API should never be forwarded to the leader #9286

@Tema

Description

@Tema

Bug Report

/ready API was added to return whether pd follower is ready to became leader:

// @Summary It will return whether pd follower is ready to became leader.
It should never be forwarded to the leader.

Right now it returns true even if regions are not loaded and it won't be ready to serve regions if promoted to the leader.

What did you do?

Restart a follower and issue /ready request right away while regions were still not loaded by the follower.

What did you expect to see?

Follower should always evaluate readiness locally w/o forwarding it to the leader. /ready should return false until regions are loaded.

What did you see instead?

Follower forwarded /ready request to leader and returned true.

What version of PD are you using (pd-server -V)?

Release Version: v9.0.0-beta.1.pre-99-gde4bc50f
Edition: Community
Git Commit Hash: de4bc50fa42d4d54aff2d76d66ded08f41f62492

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions