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

Add extend ability to query external service for autoscaler #2279

Merged
merged 34 commits into from
May 6, 2020

Conversation

Yisaer
Copy link
Contributor

@Yisaer Yisaer commented Apr 23, 2020

What problem does this PR solve?

Close #2235

Add extend ability to query external service for autoscaler to let community user could use their own strategy to adjust the auto-scaling.

Related changes

  • Need to cherry-pick to the release branch
  • Need to update the documentation

Does this PR introduce a user-facing change?:

Make `TidbClusterAutoScaler` have ther external strategy ability

@Yisaer
Copy link
Contributor Author

Yisaer commented Apr 28, 2020

@cofyc @DanielZhangQD @weekface PTAL

pkg/apis/pingcap/v1alpha1/tidbclusterautoscaler_types.go Outdated Show resolved Hide resolved
pkg/apis/pingcap/v1alpha1/tidbclusterautoscaler_types.go Outdated Show resolved Hide resolved
pkg/apis/pingcap/v1alpha1/tidbclusterautoscaler_types.go Outdated Show resolved Hide resolved
pkg/apis/pingcap/v1alpha1/tidbclusterautoscaler_types.go Outdated Show resolved Hide resolved
Comment on lines 65 to 67
client = &http.Client{Transport: tr}
} else {
client = &http.Client{}
Copy link
Contributor

Choose a reason for hiding this comment

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

Set a timeout for the client?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

updated.

pkg/autoscaler/autoscaler/query/external.go Outdated Show resolved Hide resolved
pkg/autoscaler/autoscaler/query/external.go Outdated Show resolved Hide resolved
pkg/autoscaler/autoscaler/tidb_autoscaler.go Outdated Show resolved Hide resolved
pkg/autoscaler/autoscaler/tikv_autoscaler.go Outdated Show resolved Hide resolved
Yisaer and others added 9 commits April 29, 2020 11:09
Co-Authored-By: DanielZhangQD <36026334+DanielZhangQD@users.noreply.github.com>
Co-Authored-By: DanielZhangQD <36026334+DanielZhangQD@users.noreply.github.com>
Co-Authored-By: DanielZhangQD <36026334+DanielZhangQD@users.noreply.github.com>
Co-Authored-By: DanielZhangQD <36026334+DanielZhangQD@users.noreply.github.com>
Co-Authored-By: DanielZhangQD <36026334+DanielZhangQD@users.noreply.github.com>
Co-Authored-By: DanielZhangQD <36026334+DanielZhangQD@users.noreply.github.com>
Co-Authored-By: DanielZhangQD <36026334+DanielZhangQD@users.noreply.github.com>
Co-Authored-By: DanielZhangQD <36026334+DanielZhangQD@users.noreply.github.com>
Co-Authored-By: DanielZhangQD <36026334+DanielZhangQD@users.noreply.github.com>
Yisaer and others added 6 commits April 29, 2020 11:12
Co-Authored-By: DanielZhangQD <36026334+DanielZhangQD@users.noreply.github.com>
Co-Authored-By: DanielZhangQD <36026334+DanielZhangQD@users.noreply.github.com>
Co-Authored-By: DanielZhangQD <36026334+DanielZhangQD@users.noreply.github.com>
DanielZhangQD
DanielZhangQD previously approved these changes Apr 29, 2020
Copy link
Contributor

@DanielZhangQD DanielZhangQD left a comment

Choose a reason for hiding this comment

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

LGTM

DanielZhangQD
DanielZhangQD previously approved these changes Apr 30, 2020
Copy link
Contributor

@DanielZhangQD DanielZhangQD left a comment

Choose a reason for hiding this comment

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

LGTM

@sunzhuohang
Copy link
Contributor

LGTM

Co-authored-by: weekface <weekface@gmail.com>
Copy link
Contributor

@DanielZhangQD DanielZhangQD left a comment

Choose a reason for hiding this comment

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

LGTM

@Yisaer Yisaer merged commit 3485e77 into pingcap:master May 6, 2020
@sre-bot
Copy link
Contributor

sre-bot commented May 6, 2020

cherry pick to release-1.1 failed

Yisaer added a commit to Yisaer/tidb-operator that referenced this pull request May 6, 2020
Yisaer added a commit that referenced this pull request May 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants