lanto03 / couchdb-python

Automatically exported from code.google.com/p/couchdb-python
Other
0 stars 0 forks source link

Support HTTP proxy #135

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
Any HTTP-based protocol should have an API that permits inserting HTTP proxy 
information.

Original issue reported on code.google.com by chadmill on 18 Jun 2010 at 8:39

GoogleCodeExporter commented 8 years ago
Darn, I can't assign this to myself.

Original comment by chadmill on 18 Jun 2010 at 8:39

GoogleCodeExporter commented 8 years ago
First attempt at support.

Original comment by chadmill on 18 Jun 2010 at 8:54

Attachments:

GoogleCodeExporter commented 8 years ago
Would it be possible to mock up some proxy server to we can test this?

Original comment by djc.ochtman on 22 Dec 2010 at 9:12

GoogleCodeExporter commented 8 years ago
Hi Dirkjan, I have a new patch for this that is battle tested. I can also 
provide testing information. If you are willing to do an official 0.9.1 / 
0.10.0 for this feature I'd love to contribute it. 

Let me know,
Joan (@wohali / freenode Wohali)

Original comment by woh...@gmail.com on 19 Feb 2014 at 7:15

GoogleCodeExporter commented 8 years ago
Yes, please, can you attach the patch here!

Original comment by djc.ochtman on 19 Feb 2014 at 7:45

GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
[deleted comment]
GoogleCodeExporter commented 8 years ago
Here is the unified patch.

---
Testing approach:

1. Install Java and browsermob-proxy from http://bmp.lightbody.net/ .
2. On any UNIX, run browsermob-proxy and configure a proxy at port 9091 via:

  /path/to/browsermob-proxy -po 9090 >~/proxy.log.$$ 2>&1 &
  curl -X POST -d "port=9091" http://localhost:9090/proxy >/dev/null 2>&1

3. Test script:

>>> server = Server(proxy_settings={"port": "9091"})  # http and localhost are 
defaulted
>>> db = server.create('python-tests')
...

4. Validate with ~/proxy.log.<pid> that all expected requests went through the 
web proxy, not direct.

---

Please let me know ASAP if there are any problems you encounter, I am highly 
motivated to help you get a point release out with this patch ;)

Original comment by woh...@gmail.com on 19 Feb 2014 at 9:32

Attachments:

GoogleCodeExporter commented 8 years ago
This issue has been migrated to GitHub. Please continue discussion here:

https://github.com/djc/couchdb-python/issues/135

Original comment by djc.ochtman on 15 Jul 2014 at 7:18