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

schedule: take op influence in shouldBalance #822

Merged
merged 11 commits into from Oct 31, 2017

Conversation

Projects
None yet
4 participants
@Connor1996
Member

Connor1996 commented Oct 26, 2017

opInfluence record difference that unfinished op steps make

Show outdated Hide outdated server/coordinator.go
Show outdated Hide outdated server/schedule/basic_cluster.go
Show outdated Hide outdated server/schedule/operator.go

@Connor1996 Connor1996 requested review from siddontang and nolouch Oct 27, 2017

Show outdated Hide outdated server/schedule/basic_cluster.go
Show outdated Hide outdated server/schedule/basic_cluster.go
Show outdated Hide outdated server/schedulers/utils.go

@disksing disksing added this to the 1.1 milestone Oct 27, 2017

Connor1996 added some commits Oct 30, 2017

from := opInfluence.GetStoreInfluence(tl.FromStore)
to := opInfluence.GetStoreInfluence(tl.ToStore)
from.LeaderSize -= int(region.ApproximateSize)

This comment has been minimized.

@siddontang

siddontang Oct 31, 2017

Member

need to check < 0 here?

@siddontang

siddontang Oct 31, 2017

Member

need to check < 0 here?

This comment has been minimized.

@Connor1996

Connor1996 Oct 31, 2017

Member

check ApproximateSize < 0 ?

@Connor1996

Connor1996 Oct 31, 2017

Member

check ApproximateSize < 0 ?

This comment has been minimized.

@siddontang

siddontang Oct 31, 2017

Member

need to check leadersize < approximate size ?

@siddontang

siddontang Oct 31, 2017

Member

need to check leadersize < approximate size ?

This comment has been minimized.

@Connor1996

Connor1996 Oct 31, 2017

Member

opInfluence is difference value, negative here means operator will make leaderSize decrease.

@Connor1996

Connor1996 Oct 31, 2017

Member

opInfluence is difference value, negative here means operator will make leaderSize decrease.

This comment has been minimized.

@siddontang

siddontang Oct 31, 2017

Member

got it

@siddontang
@siddontang

This comment has been minimized.

Show comment
Hide comment
@siddontang
Member

siddontang commented Oct 31, 2017

@disksing

LGTM.

@disksing

This comment has been minimized.

Show comment
Hide comment
@disksing

disksing Oct 31, 2017

Member

/run-all-tests

Member

disksing commented Oct 31, 2017

/run-all-tests

@Connor1996 Connor1996 merged commit 3060905 into pingcap:master Oct 31, 2017

4 checks passed

ci/circleci Your tests passed on CircleCI!
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
jenkins-ci-pd/build Jenkins job succeeded.
Details
license/cla Contributor License Agreement is signed.
Details

@Connor1996 Connor1996 deleted the Connor1996:connor/op-influence branch Oct 31, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment