Closed daveschaefer closed 8 years ago
I ran some brief tests of nginx in front of CherryPy on a basic EC2 machine. The results were fantastic.
Test: spam the server with requests (some valid, some not), 200 RPS for 60 seconds. Run test ten times and take the average of all runs.
Regular version 2.0 notary, with no caching: 744 Hits/s 81 errors, 4037 timeouts, 1178 ms response time. That is 12.4 Hits/s.
Same notary, with nginx in front of the server: 7,725 hits with 23 errors & 57 timeouts 516ms response time. That is 128 hits/second.
This was with no optimization or notary code/config changes. I simply put an nginx reverse proxy in front of the notary. With some nginx config tweaks we may be able to get even better performance.
This was fixed in #52 - added doc and basic config.
We could still add netsafe's config for other uses, but the basic stuff is already there. Closing this ticket.
As mentioned in #19, the suggested easy route for increasing CherryPy performance is to place CherryPy behind another server that is meant to be fast and scalable, such as nginx.
Let's create some nginx config files we can use to quickly and easily deploy on notary servers. We can then implement https (#19) and upgrade to higher notary versions later and separately. Adding nginx will let us make the servers responsive again.
We can probably create one set of configs for the default notaries, which should serve ports 8080 (for backwards compatibility), 80, and eventually 443. Other notaries that do not need to serve 8080 can have a config that only servers 80 and eventually 443.