Add ACL Mapping for Dex Send and Cancel orders #360
Conversation
bef4221 to
e1c9f49
Compare
app/app.go
Outdated
| if val, ok := channelsMapping[messageIndex]; ok { | ||
| channels = val[accessOperation] | ||
| } else { | ||
| channelsMapping[messageIndex] = make(sdkacltypes.AccessOpsChannelMapping) | ||
| } | ||
|
|
There was a problem hiding this comment.
This was a bug, added a unit test to catch this. This resets the channelMapping for each index every time so we really only have one accessOperation channel to signal off. Probably less of a problem when we had much simpler messaging dependencies previously it would happen periodically but now it's consistently happening.
app/app.go
Outdated
| var channels []chan interface{} | ||
| channelsMapping[messageIndex] = make(sdkacltypes.AccessOpsChannelMapping) | ||
| if val, ok := channelsMapping[messageIndex]; ok { | ||
| channels = val[accessOperation] |
There was a problem hiding this comment.
why do we need to get the channels here? since we're iterating over accessOperation, shouldnt we be starting with a fresh slice each iteration? (aka there shouldnt be an entry for val[accessOperation] right?
There was a problem hiding this comment.
Im gonna remove this if statement entirely, we can move channelsMapping[messageIndex] = make(sdkacltypes.AccessOpsChannelMapping)to the outer loop so it's only instantiated once
loadtest/config.json
Outdated
| "market_order_percentage": "0.8" | ||
| }, | ||
| "message_type": "dex", | ||
| "run_oracle": true, |
There was a problem hiding this comment.
nit: you might want to leave run_oracle false since idt your ansible script (or the one committed in master) has the steps for getting validator keys
loadtest/main.go
Outdated
| Orders: orderPlacements, | ||
| ContractAddr: contract, | ||
| Funds: amount, | ||
| msgType := c.LoadTestConfig.MsgTypeDistr.SampleDexMsgs() |
There was a problem hiding this comment.
can you rebase your loadtest script onto cherry-pick-parallel instead of 2.0.0beta? theres several changes made there that I'd prefer get included by default instead of rebasing conflicts
There was a problem hiding this comment.
Im getting a lot of merge conflicts when trying to rebase it on loadtest/main.go, maybe i can just revert the loadtest/changes to 2.0.0beta and make the loadtest/changes against your branch in another PR?
* Implement DEX parallelization * Remove print * sd * check out loadtest to 2.0.0beta * fix Co-authored-by: Eric Zhu <ericzhu77@gmail.com>
* Implement DEX parallelization * Remove print * sd * check out loadtest to 2.0.0beta * fix Co-authored-by: Eric Zhu <ericzhu77@gmail.com>
* Implement DEX parallelization * Remove print * sd * check out loadtest to 2.0.0beta * fix Co-authored-by: Eric Zhu <ericzhu77@gmail.com>
* Revert "Revert "Rebase 2.0.0beta Parallelization onto master" (#357)" This reverts commit 977c1d1. * Add ACL Mapping for Dex Send and Cancel orders (#360) * Implement DEX parallelization * Remove print * sd * check out loadtest to 2.0.0beta * fix Co-authored-by: Eric Zhu <ericzhu77@gmail.com> * bump version * Small Refactor for loadtest script (#362) * sample * more money * lint Co-authored-by: Brandon Weng <18161326+BrandonWeng@users.noreply.github.com> Co-authored-by: Eric Zhu <ericzhu77@gmail.com>
* Revert "Revert "Rebase 2.0.0beta Parallelization onto master" (#357)" This reverts commit 977c1d1. * Add ACL Mapping for Dex Send and Cancel orders (#360) * Implement DEX parallelization * Remove print * sd * check out loadtest to 2.0.0beta * fix Co-authored-by: Eric Zhu <ericzhu77@gmail.com> * bump version * Small Refactor for loadtest script (#362) * sample * more money * lint Co-authored-by: Brandon Weng <18161326+BrandonWeng@users.noreply.github.com> Co-authored-by: Eric Zhu <ericzhu77@gmail.com>
- To avoid multiple deserialization, as well as adding cached values to sdk.Tx - Add new acl constants for evm subprefixes - Add a new bank send method that doesn't automatically create accounts unit tests & local sei integration
- To avoid multiple deserialization, as well as adding cached values to sdk.Tx - Add new acl constants for evm subprefixes - Add a new bank send method that doesn't automatically create accounts unit tests & local sei integration
Describe your changes and provide context
From Eric's changes: Also updates load testing script to send cancellation orders
Testing performed to validate your change
Mainly unit tests for now - trying to run e2e with loadtest cluster