use threading.local() for http connections