-
Notifications
You must be signed in to change notification settings - Fork 7
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
Loadgen runner #12
Loadgen runner #12
Conversation
Don't sleep negative time
Capture chain storage at the end of every stage
Rename loadGen -> loadgen
Close slog fifo stream when chain process has started but swingset hasn't yet
The perf script would ignore directed signals while sleeping or waiting for docker, launch those in the background instead and wait on them. Send a term signal to docker instead of stopping to prevent abrupt kill Streamline signal handling logic
bdb6aa4
to
c0f1db6
Compare
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.
Yay!
Fix eslint-config dependency
Do not fail fast, but avoid exec races
6896aab
to
94f9678
Compare
@warner let me know if the readme and PR description make sense. |
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.
Yeah, that looks good.. it might be good to have an extra paragraph or two near the top as a "welcome testnet validators!" instruction guide, to distinguish between using this repo for dailyperf purposes and using it to complete the run-a-loadgen task that we've asked them to do.
I'm gonna fast follow up with another PR that fixes the AMM task and moves the readme, replacing it with something more appropriate. |
Summary
This (large) PR introduces a runner capable of orchestrating a chain node, a client ag-solo and the existing loadgen script, as well as several wrapper scripts to automate running the loadgen using any SDK revision, in the expected environment.
It's the base for running a daily loadgen on the latest agoric-sdk to capture historical performance data. See Agoric/agoric-sdk#2630
The orchestrator starts a local chain node (or monitor node in the case of an remote chain), pipes and parses the slog using a FIFO file, and monitors events from the slog. At regular interval, it captures process information for the CPU usage of the chain process and its vat subprocesses, as well as the disk storage used by the chain. It can run multiple cycles of chain, client and loadgen, compressing and saving the chain storage and raw slog for every stage.
Runner structure
The runner is setup as a node workspace package. Unlike the
loadgen
package, it doesn't depend on agoric-sdk. Since it tries to follow code patterns, it runs under SES using its owninstall-ses
and uses a fork ofpromise-kit
, mainly to avoid breaking changes such as RESM->NESM.The runner is a CLI application composed of a
main.js
file parsing the command line and implementing the bulk of the orchestration logic. It relies ontasks
that implement the specifics of setting up and running a chain node, running a local solo client, and running the load generator itself, all spawned as sub processes. Currently it supports running these tasks for a local chain, or against an externalstage
andtestnet
chain. The implementation uses a bunch of potentially reusable async, stream, process and filesystem helpers (currently not covered by any unit tests).The output of all spawned sub processes is combined and prefixed into the stdout of the runner.