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

Removed old scheduler constructor. #45472

Merged
merged 1 commit into from
May 8, 2017

Conversation

k82cn
Copy link
Member

@k82cn k82cn commented May 8, 2017

Which issue this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close that issue when PR gets merged): fixes # N/A

Release note:

@k8s-reviewable
Copy link

This change is Reviewable

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label May 8, 2017
@k8s-github-robot k8s-github-robot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. release-note Denotes a PR that will be considered when it comes time to generate release notes. labels May 8, 2017
@k82cn k82cn changed the title Removed old scheduler constructor. [WIP] Removed old scheduler constructor. May 8, 2017
@k8s-github-robot k8s-github-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels May 8, 2017
@k82cn k82cn changed the title [WIP] Removed old scheduler constructor. Removed old scheduler constructor. May 8, 2017
s := &Scheduler{
config: c,
}
metrics.Register()
Copy link
Member

Choose a reason for hiding this comment

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

What is registering metrics now?

Copy link
Member Author

Choose a reason for hiding this comment

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

New is replaced by NewFromConfigurator now. New is not use in kube-scheduler but tests, I'm updating code for them.


type FakeConfigurator struct {
Config *Config
PriorityConfigs []algorithm.PriorityConfig
Copy link
Member

Choose a reason for hiding this comment

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

All of these seems to be unused in all usecases.
Unless you see a good reason to have them (I don't), I really suggest removing all of these fields.

And all accessort functions can simple return nils (which they already do) or errors "not implemented" (if it won't break anything).

Copy link
Member Author

Choose a reason for hiding this comment

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

Good point, I'll update it.

@wojtek-t
Copy link
Member

wojtek-t commented May 8, 2017

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label May 8, 2017
@k8s-github-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: k82cn, wojtek-t

Needs approval from an approver in each of these OWNERS Files:

You can indicate your approval by writing /approve in a comment
You can cancel your approval by writing /approve cancel in a comment

@k8s-github-robot k8s-github-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label May 8, 2017
@k8s-github-robot
Copy link

Automatic merge from submit-queue (batch tested with PRs 41903, 45311, 45474, 45472, 45501)

@k8s-github-robot k8s-github-robot merged commit d13c42d into kubernetes:master May 8, 2017
@k82cn k82cn deleted the rm_unused_func branch May 9, 2017 00:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants