Multi-threaded web proxy in python