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

config: ignore tiflash when show config #24770

Merged
merged 8 commits into from
May 20, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions executor/memtable_reader.go
Original file line number Diff line number Diff line change
Expand Up @@ -191,6 +191,9 @@ func fetchClusterConfig(sctx sessionctx.Context, nodeTypes, nodeAddrs set.String
url = fmt.Sprintf("%s://%s%s", util.InternalHTTPSchema(), statusAddr, pdapi.Config)
case "tikv", "tidb":
url = fmt.Sprintf("%s://%s/config", util.InternalHTTPSchema(), statusAddr)
case "tiflash":
// TODO: support show tiflash config once tiflash supports it
return
default:
ch <- result{err: errors.Errorf("unknown node type: %s(%s)", typ, address)}
return
Expand Down
2 changes: 1 addition & 1 deletion executor/memtable_reader_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ func (s *testMemTableReaderSuite) TestTiDBClusterConfig(c *C) {

// mock servers
servers := []string{}
for _, typ := range []string{"tidb", "tikv", "pd"} {
for _, typ := range []string{"tidb", "tikv", "tiflash", "pd"} {
for _, server := range testServers {
servers = append(servers, strings.Join([]string{typ, server.address, server.address}, ","))
}
Expand Down