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

go/worker/executor: update scheduling parameters on runtime updates #3222

Merged
merged 1 commit into from
Aug 28, 2020

Conversation

ptrus
Copy link
Member

@ptrus ptrus commented Aug 28, 2020

Fixes: #3203

@ptrus ptrus force-pushed the ptrus/feature/scheduler-update-parameters branch from 0740aa0 to b5bfd0c Compare August 28, 2020 09:42
Copy link
Member

@kostko kostko left a comment

Choose a reason for hiding this comment

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

Some minor nits, otherwise looks good!

// XXX: Once there is more than one scheduling algorithm available
// this might need to recreate the scheduler and reinsert
// the transactions.
// At that point also udpate the schedulerMutex usage across the
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
// At that point also udpate the schedulerMutex usage across the
// At that point also update the schedulerMutex usage across the

Algorithm: "invalid",
},
)
require.Error(t, err, "UpdateParameters invalid udpate")

Copy link
Member

Choose a reason for hiding this comment

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

Remove empty line?

// Make sure transaction doesn't get scheduled.
err = scheduler.Flush(false)
require.NoError(t, err, "Flush(force=false)")
require.Equal(t, 1, scheduler.UnscheduledSize(), "transaction should remain scheduled after a non-forced flush")
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
require.Equal(t, 1, scheduler.UnscheduledSize(), "transaction should remain scheduled after a non-forced flush")
require.Equal(t, 1, scheduler.UnscheduledSize(), "transaction should remain unscheduled after a non-forced flush")

@@ -14,7 +16,6 @@ const (
)

type scheduler struct {
cfg config
Copy link
Member

Choose a reason for hiding this comment

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

Should we also remove the config type?

@@ -0,0 +1,4 @@
Executor scheduling doesn't refresh runtime parameters
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
Executor scheduling doesn't refresh runtime parameters
Executor should refresh runtime scheduling parameters

@ptrus ptrus force-pushed the ptrus/feature/scheduler-update-parameters branch from b5bfd0c to 45ca039 Compare August 28, 2020 10:34
@codecov
Copy link

codecov bot commented Aug 28, 2020

Codecov Report

Merging #3222 into master will decrease coverage by 0.17%.
The diff coverage is 60.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #3222      +/-   ##
==========================================
- Coverage   67.47%   67.30%   -0.18%     
==========================================
  Files         370      370              
  Lines       36323    36343      +20     
==========================================
- Hits        24509    24460      -49     
- Misses       8648     8703      +55     
- Partials     3166     3180      +14     
Impacted Files Coverage Δ
go/worker/compute/executor/committee/node.go 65.66% <26.66%> (+0.09%) ⬆️
go/runtime/scheduling/init.go 66.66% <75.00%> (ø)
go/runtime/scheduling/simple/simple.go 79.68% <81.81%> (-1.98%) ⬇️
go/runtime/scheduling/simple/incoming_queue.go 96.61% <100.00%> (+0.14%) ⬆️
go/consensus/tendermint/epochtime/epochtime.go 85.71% <0.00%> (-7.94%) ⬇️
go/consensus/tendermint/abci/state/state.go 61.53% <0.00%> (-7.70%) ⬇️
...consensus/tendermint/apps/roothash/transactions.go 48.36% <0.00%> (-6.56%) ⬇️
.../consensus/tendermint/apps/epochtime_mock/state.go 74.46% <0.00%> (-4.26%) ⬇️
go/storage/metrics.go 85.13% <0.00%> (-4.06%) ⬇️
go/storage/mkvs/remove.go 85.85% <0.00%> (-4.05%) ⬇️
... and 21 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1b7ede7...45ca039. Read the comment docs.

@ptrus ptrus merged commit e732593 into master Aug 28, 2020
@ptrus ptrus deleted the ptrus/feature/scheduler-update-parameters branch August 28, 2020 11:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Executor scheduling doesn't refresh runtime parameters
2 participants