-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
Make simulation use a transition matrix for block size #2622
Conversation
This enables simulating periods of high load, and periods of low to no load. (low load because future ops will still terminate in that time frame)
Codecov Report
@@ Coverage Diff @@
## develop #2622 +/- ##
===========================================
+ Coverage 58.82% 58.84% +0.02%
===========================================
Files 152 152
Lines 9424 9424
===========================================
+ Hits 5544 5546 +2
+ Misses 3510 3508 -2
Partials 370 370 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @ValarDragon -- left some feedback :-)
func createBlockSimulator(testingMode bool, tb testing.TB, t *testing.T, event func(string), invariants []Invariant, ops []WeightedOperation, operationQueue map[int][]Operation, timeOperationQueue []FutureOperation, totalNumBlocks int, displayLogs func()) func( | ||
blocksize int, r *rand.Rand, app *baseapp.BaseApp, ctx sdk.Context, accounts []Account, header abci.Header, logWriter func(string)) (opCount int) { | ||
totalOpWeight := 0 | ||
func createBlockSimulator(testingMode bool, tb testing.TB, t *testing.T, event func(string), invariants []Invariant, ops []WeightedOperation, operationQueue map[int][]Operation, timeOperationQueue []FutureOperation, totalNumBlocks int, avgBlockSize int, displayLogs func()) func( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This function signature is extremely hard to read. I think it's not a big change to clean it up here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Refactoring it properly will involve wrapping up parameters into structs, but I can split into multipleines here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
++
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
made a general comment improvement, but testedACK 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
utACK, 🎃
This enables simulating periods of high load, and periods of low to no load.
(low load because future ops will still terminate in that time frame)
Once this is merged, I think we should just delete #1924, and make a new issue tagged postlaunch for those remaining items.
The LCD change is from make format.
Targeted PR against correct branch (see CONTRIBUTING.md)
Linked to github-issue with discussion and accepted design OR link to spec that describes this work.
Added entries in
PENDING.md
with issue #rereviewed
Files changed
in the github PR explorerFor Admin Use: