Skip to content
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

SSR with high traffic #298

Open
anhdn opened this issue Jul 7, 2017 · 11 comments
Open

SSR with high traffic #298

anhdn opened this issue Jul 7, 2017 · 11 comments

Comments

@anhdn
Copy link

anhdn commented Jul 7, 2017

Hi,

Firstly, thanks @bertho-zero for continuing contribute this repo.

I have an issue with high traffic, the server responses first time very slowly. It can not handle 20 request / second although i use server with 8 core 8 Gb memory. I checked CPU, Memory number are still normally. Maybe it was blocked by node single thread.
We have a SSR issue with high traffic. Does anyone have solution for this?

Thanks!

@bertho-zero
Copy link
Owner

You mean that you should add a cluster manager or use pm2 and pm2 scale?

@anhdn
Copy link
Author

anhdn commented Jul 7, 2017

I used pm2 scale 8 to increase node process but it did not affect.

@MHerszak
Copy link

I am facing the same issue and I believe it is necessary to prebuild Webpack and ship the frontend to a CDN. This will help a lot with your first load. What are your thoughts @bertho-zero ?

@anhdn
Copy link
Author

anhdn commented Oct 22, 2017

I'm using varnish cache.

@bertho-zero
Copy link
Owner

React 16 increases server side rendering performance by 2-3 times.

@Swapnilchavan18
Copy link

I am also having same issue of server side rendering, it takes more time(6-7 seconds) for large component tree, Anyone found solution on this?

@bertho-zero
Copy link
Owner

@MHerszak Have you tested the use of a CDN? I would like to know, if possible, the potential gains.

@anhdn Does this mean that the problem is fixed with varnish cache?

If you have more details about the cause of the problems with high-traffic, do not hesitate to share.

@MHerszak
Copy link

@bertho-zero I am going to use a CDN in the near future. But this will not fix the problem on first load which is the only problem I have. As soon it is cached it is fine.

@anhdn
Copy link
Author

anhdn commented Nov 23, 2017

@bertho-zero we use varnish to cache html. But i think you should upgrade to react 16, improve performance of ssr a lots.

@bertho-zero
Copy link
Owner

bertho-zero commented Nov 23, 2017

@anhdn I upgraded to react 16, which is between 2 and 4 times faster with SSR.

@bertho-zero
Copy link
Owner

News for that since all these updates?

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

No branches or pull requests

4 participants