-
Notifications
You must be signed in to change notification settings - Fork 17
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 Express faster! Let's improve our benchmarks ⚡ #261
Comments
Hi @andrehrferreira, Thanks for bringing this topic up. I'll transfer this issue to the discussions repo for better visibility. Right now, our main focus is on Express@5, which we believe will be faster than Express@4 due to the significant changes we've introduced. That said, our current benchmarks still need improvement. Our plan is to concentrate on comparing different Express releases rather than benchmarking against other projects. Fastify, for example, already provides great comparison tool: https://fastify.dev/benchmarks/ (https://github.com/fastify/benchmarks/). After we release v5, we can shift our efforts towards further optimizing Express. In the meantime, we could add more test cases and include benchmarks for our direct dependencies, such as body-parser. Is this something you'd be interested in working on? |
Of course I can help, just tell me what types of tests you think are interesting to optimize the performance of the packages that I eventually work on implementing. I currently work on developing multiplayer game servers, so I end up performing a lot of performance tests both at the protocol level and in applications and languages, so it would be a pleasure to help with whatever is needed. |
Related: #306 Just posting to add that link, once I am caught up on the notifications I am going to circle back on that proposal and start putting together some plans on how we should approach this problem. |
Hey guys, how are you? I took some time off to take a year-end break, I recently performed some tests using my integration tool with the Node.js inspector, I'll leave the link to the test repository, https://github.com/andrehrferreira/express-benchmarks, the test is very simple, I uploaded an instance of express without any middleware and performed the monitoring using the inspector, then I used autocannon to trigger multiple requests in this application using the command autocannon -c 100 -d 40 -p 10 localhost:3000 As a result, my system creates a cpuprofile file that I analyze using the application https://discoveryjs.github.io/cpupro, I'll leave the profile file in the repository for deeper analysis, but basically, 37.5% of the processing time was from internal express functions, with 13.8% from response.js and 9% from the router, which in my opinion are the main ones bottlenecks of the current version, 7.3% in middleware/init.js, looking deeper the most worrying is in fact the send function for response, followed by the header and contentType, as I had already commented before in my point of view the main problem is in the use of Object.defineProperty, however I will continue analyzing other important points to be optimized |
Hello everyone, I am performing a performance test between several http servers in node.js and I noticed that Express is performing much lower than the others, due to the fact that I use Express in practically all my projects. I would like to know if there are already people collaborating in improving the performance of the project, if not, would you like to start studies to improve these results?, since in my opinion Express is the most relevant and used among all, below are the test results, and the script I sent via pull request.
The tests were performed on Ubuntu 20.04.6 LTS via WSL 2 on Windows 10, my computer configuration is an Intel Core i9 10980 XE, 256 GB of DDR4 ram, 2TB nvme EVO pro SSD, NVidia Asus Rog RTX 3080 TI, Node v18.16.1
The text was updated successfully, but these errors were encountered: