Chapter 18.2.1. Advantages/Drawbacks of Using a Proxy in front of CherryPy

The advantages of this method are as follows:

  • Easy to set up.

  • You can still access your CherryPy directly (by using the port number), which is nice for debugging.

  • It’s fast. (Rough tests have shown that the overhead associated with forwarding the request/response can be as little as 1ms per request.)

The drawbacks of this method are as follows:

  • You have to use special headers to get the actual Host header of the request and the IP address of the browser. This is because to CherryPy, requests will look like they come from the local Apache server rather than the remote browser. In the case of Apache, you get the original Host header in the X-Forwarded-Host header and the ...

Get Rapid Web Applications with TurboGears: Using Python to Create Ajax-Powered Sites now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.