igrigorik/em-proxy — Issue #18: HTTPProxy Example Incorrect
Author: JohnMurray
Created: 2011-12-15 13:58:33+00:00
State: open

I am new the EventMachien and em-proxy but, it doesn't take long to realize that the HTTPProxy example is either incorrect or not robust enough for actual use.

I ran the proxy and then accessed Google Maps in my web browser and the results were very interesting. Various images were swapped and loaded incorrectly. I tried a variety of other sites and the same problem kept appearing. It seems that the proxy was sending the wrong response for the requests. If the web page requested an icon picture, it might return the profile picture instead.

It would be really helpful if this example could be updated to be more robust. In it's current state, it is a poor example. I would like to contribute to this example. However, I have unfortunately been banging my head against the wall for too long now and have moved on to using the Webrick HTTPProxy for now as it serves my current needs well. I'm am not sure how to approach this problem and will not know until I take more time to learn EventMachine (a relatively new item on my list).