Skip to content

Run React in production mode#7

Merged
mcollina merged 1 commit intoplatformatic:mainfrom
gaearon:patch-1
Aug 28, 2024
Merged

Run React in production mode#7
mcollina merged 1 commit intoplatformatic:mainfrom
gaearon:patch-1

Conversation

@gaearon
Copy link
Copy Markdown
Contributor

@gaearon gaearon commented Aug 28, 2024

React runs additional checks in development. This is why, when running React in production, or when benchmarking it, it is important to turn on production mode.

Before

┌─────────┬───────┬───────┬───────┬────────┬──────────┬──────────┬────────┐
│ Stat    │ 2.5%  │ 50%   │ 97.5% │ 99%    │ Avg      │ Stdev    │ Max    │
├─────────┼───────┼───────┼───────┼────────┼──────────┼──────────┼────────┤
│ Latency │ 45 ms │ 47 ms │ 96 ms │ 100 ms │ 53.22 ms │ 14.55 ms │ 130 ms │
└─────────┴───────┴───────┴───────┴────────┴──────────┴──────────┴────────┘
┌───────────┬───────┬───────┬─────────┬─────────┬─────────┬────────┬───────┐
│ Stat      │ 1%    │ 2.5%  │ 50%     │ 97.5%   │ Avg     │ Stdev  │ Min   │
├───────────┼───────┼───────┼─────────┼─────────┼─────────┼────────┼───────┤
│ Req/Sec   │ 178   │ 178   │ 184     │ 189     │ 185.7   │ 3.41   │ 178   │
├───────────┼───────┼───────┼─────────┼─────────┼─────────┼────────┼───────┤
│ Bytes/Sec │ 35 MB │ 35 MB │ 36.1 MB │ 37.1 MB │ 36.5 MB │ 670 kB │ 35 MB │

After

│ Stat    │ 2.5%  │ 50%   │ 97.5% │ 99%   │ Avg      │ Stdev   │ Max   │
├─────────┼───────┼───────┼───────┼───────┼──────────┼─────────┼───────┤
│ Latency │ 10 ms │ 11 ms │ 29 ms │ 35 ms │ 13.29 ms │ 5.42 ms │ 55 ms │
└─────────┴───────┴───────┴───────┴───────┴──────────┴─────────┴───────┘
┌───────────┬────────┬────────┬────────┬────────┬────────┬─────────┬────────┐
│ Stat      │ 1%     │ 2.5%   │ 50%    │ 97.5%  │ Avg    │ Stdev   │ Min    │
├───────────┼────────┼────────┼────────┼────────┼────────┼─────────┼────────┤
│ Req/Sec   │ 682    │ 682    │ 726    │ 734    │ 722.46 │ 15.08   │ 682    │
├───────────┼────────┼────────┼────────┼────────┼────────┼─────────┼────────┤
│ Bytes/Sec │ 134 MB │ 134 MB │ 143 MB │ 144 MB │ 142 MB │ 2.95 MB │ 134 MB │
└───────────┴────────┴────────┴────────┴────────┴────────┴─────────┴────────┘

Copy link
Copy Markdown
Member

@mcollina mcollina left a comment

Choose a reason for hiding this comment

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

lgtm thanks!

🤦‍♂️

@mcollina mcollina merged commit 13d84a9 into platformatic:main Aug 28, 2024
Copy link
Copy Markdown

@mhdcodes mhdcodes left a comment

Choose a reason for hiding this comment

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

🔥

aoede3 added a commit to aoede3/taujs that referenced this pull request Nov 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants