pingcap / pingcap/tiup

Upgrade process use the wrong URL

Open
#1,452 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

type/bug
Dominant language
Go
Stars
466
Forks
338
Avg merge
3d 7h
Merged PRs (30d)
8

Description

Bug Report

Please answer these questions before submitting your issue. Thanks!

  1. What did you do?
    Upgrade cluster

  2. What did you expect to see?
    Successfully

  3. What did you see instead?

Upgrading component tikv
failed increasing schedule limit: no endpoint available, the last err was: error requesting http://10.4.101.105:2379/pd/api/v1/config/replication-mode, response: {
"code": "input",
"msg": "unexpected end of JSON input",
"data":

{ "Offset": 0 }

See https://github.com/pingcap/tiup/blob/49ee71a1e3efc77793fed1ddcaa37a6965ac5845/pkg/cluster/operation/upgrade.go#L223

https://github.com/pingcap/tiup/blob/49ee71a1e3efc77793fed1ddcaa37a6965ac5845/pkg/cluster/api/pdapi.go#L771

For xxx-schedule-limit, we should use pd/api/v1/config or pd/api/v1/config/schedule instead of pd/api/v1/config/replication-mode. replication-mode hasn't GA for now.

  1. What version of TiUP are you using (tiup --version)?
    master

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.

Research direction

Start by reading pkg/cluster/operation/upgrade.go around line 223 and pkg/cluster/api/pdapi.go around line 771. Trace how the xxx-schedule-limit request is assembled, then verify that cluster upgrade uses the supported PD configuration endpoint and no longer produces the reported replication-mode error.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
cli, devops
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.