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
PLT-9014 Query volume benchmarking for Marlowe Runtime #795
Conversation
run metric pageSize query filters = | ||
do | ||
start <- liftIO getPOSIXTime | ||
Statistics{..} <- foldlM ((runMarloweQueryClient .) . benchmark start pageSize) def filters |
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.
Note because MarloweQueryClient
is a monad this could be
Statistics{..} <- foldlM ((runMarloweQueryClient .) . benchmark start pageSize) def filters | |
Statistics{..} <- runMarloweQueryClient $ foldlM (benchmark start pageSize) def filters |
The difference is that you don't establish a new connection for each filter. I'll leave it up to you to decide if this is what you want or not.
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.
I kept that foldM
outermost because I thought that might be a bit more stressful to the backend service. Normally, I would have put runMarloweQueryClient
on the outside, for efficiency.
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.
Nice, I think this a good place to start the design.
This PR provides configurable volume/load tests for the following Marlowe Runtime protocols:
BulkSync
HeaderSync
Sync
Query
See https://github.com/input-output-hk/marlowe-cardano/tree/PLT-9014/marlowe-benchmark#readme for documentation and example output.
Subsequent PRs will address other protocols and data management for reporting.
Pre-submit checklist: