Skip to content

Conversation

@wesleytodd
Copy link
Member

Took a quick look at converting @RafaelGSS's local server/client into a runner. I didn't have time this morning to look at the wrk2/autocannon stuff, but can assuming that #62 was not trying to say "ditch that abstraction entirely", which maybe it is and then I would like to discuss why we should do that.

@wesleytodd
Copy link
Member Author

There are still quite a few gaps:

  • Sorting out local installs for the CLI's (global installs are a no go imo)
  • Finding the right format for passing requests to wrk2 like we do to autocannon
  • Applying overrides
  • Decide how we would want to support the --node option (maybe this one doesn't since it would use what node you have locally)

But @RafaelGSS are you alright with this direction so that we align with the other runner styles and features?

Copy link
Contributor

@RafaelGSS RafaelGSS left a comment

Choose a reason for hiding this comment

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

Sorry delay, @wesleytodd, a lot of things are going on recently, as you might know.

To be honest, I was trying to say "ditch that abstraction entirely" - It's a personal preference, so I'm fine leaving it as internal packages. My feeling that this increases the contribution barrier and makes things overly complex.

Also, I do believe Wrk2 (at least) should be a global binary - making it available through this CLI will make things very complex as the binary needs different dependencies according to each supported environment. Leaving that open for the "sysadmin" seems a better choice to not make things more complex than it is nowadays.

(That's what we do for Node.js too)

@RafaelGSS
Copy link
Contributor

Ping me when this is ready to review @wesleytodd

@wesleytodd
Copy link
Member Author

wesleytodd commented Dec 1, 2025

Will do, just cleaning things up and will move it from draft when it is ready.

@wesleytodd wesleytodd force-pushed the add-local-server-runner branch from 5a5c185 to 3499db7 Compare December 1, 2025 13:35
cli: add local-bench to exbf

Output example

> @expressjs/perf-wg@1.0.0 local-load
> expf local-load

Running autocannon load...
Result Autocannon: 121610.67
Running wrk2 load...
Result Wrk2: [
  { percentile: 50, ms: 0.829 },
  { percentile: 75, ms: 1.1 },
  { percentile: 90, ms: 1.41 },
  { percentile: 99, ms: 1.75 },
  { percentile: 99.9, ms: 1.88 },
  { percentile: 99.99, ms: 2 },
  { percentile: 99.999, ms: 2.2 },
  { percentile: 100, ms: 2.2 }
]
@wesleytodd wesleytodd force-pushed the add-local-server-runner branch from 3499db7 to e764ef6 Compare December 1, 2025 14:07
@wesleytodd wesleytodd force-pushed the add-local-server-runner branch 2 times, most recently from 2870e11 to ce4622a Compare December 2, 2025 15:33
@wesleytodd wesleytodd force-pushed the add-local-server-runner branch from ce4622a to a61605e Compare December 2, 2025 15:51

// TODO: I don't see docs on how to do this with wrk2
if (opts.method || this.method) {
throw new Error('not yet supported');
Copy link
Member Author

Choose a reason for hiding this comment

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

method and body did not show up in the readme and since I didn't get wrk2 building on my mac I just left these here for now. We should fix this before merging.

Copy link
Contributor

Choose a reason for hiding this comment

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

I can test it.

@wesleytodd wesleytodd marked this pull request as ready for review December 2, 2025 15:58
@wesleytodd wesleytodd requested a review from a team December 2, 2025 15:58
Copy link
Contributor

@RafaelGSS RafaelGSS left a comment

Choose a reason for hiding this comment

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

I think it's also missing a doc update.


// TODO: I don't see docs on how to do this with wrk2
if (opts.method || this.method) {
throw new Error('not yet supported');
Copy link
Contributor

Choose a reason for hiding this comment

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

I can test it.

@wesleytodd wesleytodd force-pushed the add-local-server-runner branch 2 times, most recently from ed5fc12 to 7dcde24 Compare December 4, 2025 16:18
@wesleytodd wesleytodd force-pushed the add-local-server-runner branch from 7dcde24 to fefc9f0 Compare December 9, 2025 15:56
@wesleytodd wesleytodd requested a review from a team December 11, 2025 15:40
Copy link
Member

@GroophyLifefor GroophyLifefor left a comment

Choose a reason for hiding this comment

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

I can not runned in my windows machine but I would prefer to merge this and fix in a clean pr rather than direct commits to branch or requesting changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

3 participants