summaryrefslogtreecommitdiff
path: root/docs/advanced-usage.rst
diff options
context:
space:
mode:
authorJon Wayne Parrott <jon.wayne.parrott@gmail.com>2016-06-28 13:51:17 -0700
committerJon Wayne Parrott <jon.wayne.parrott@gmail.com>2016-06-28 13:51:17 -0700
commit161a4efbd86b518a2fd1d980505eb0d2903f5ded (patch)
treef9000908e0a2909508b9139b9420f93d767f42e4 /docs/advanced-usage.rst
parentae7f533cb44838cceef79dd094018c6108d9ecc6 (diff)
downloadurllib3-161a4efbd86b518a2fd1d980505eb0d2903f5ded.tar.gz
Adding app engine docs
Diffstat (limited to 'docs/advanced-usage.rst')
-rw-r--r--docs/advanced-usage.rst29
1 files changed, 29 insertions, 0 deletions
diff --git a/docs/advanced-usage.rst b/docs/advanced-usage.rst
index 3558ffe0..45daaedb 100644
--- a/docs/advanced-usage.rst
+++ b/docs/advanced-usage.rst
@@ -145,3 +145,32 @@ Alternatively you can capture the warnings with the standard :mod:`logging` modu
Finally, you can suppress the warnings at the interpreter level by setting the
``PYTHONWARNINGS`` environment variable or by using the
`-W flag <https://docs.python.org/2/using/cmdline.html#cmdoption-W>`_.
+
+Google App Engine
+-----------------
+
+urllib3 supports `Google App Engine <https://cloud.google.com/appengine>`_ with
+some caveats.
+
+If you're using the `Flexible environment
+<https://cloud.google.com/appengine/docs/flexible/>`_, you do not have to do
+any configuration- urllib3 will just work. However, if you're using the
+`Standard environment <https://cloud.google.com/appengine/docs/python/>`_ then
+you either have to use :mod:`urllib3.contrib.appengine`'s
+:class:`~urllib3.contrib.appengine.AppEngineManager` or use the `Sockets API
+<https://cloud.google.com/appengine/docs/python/sockets/>`_
+
+To use :class:`~urllib3.contrib.appengine.AppEngineManager`::
+
+ >>> from urllib3.contrib.appengine import AppEngineManager
+ >>> http = AppEngineManager()
+ >>> http.request('GET', 'https://google.com/')
+
+To use the Sockets API, add the following to your app.yaml and use
+:class:`~urllib3.poolmanager.PoolManager` as usual::
+
+ env_variables:
+ GAE_USE_SOCKETS_HTTPLIB : 'true'
+
+For more details on the limitations and gotchas, see
+:mod:`urllib3.contrib.appengine`.