summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorDarrell Bishop <darrell@swiftstack.com>2013-06-26 22:47:49 -0700
committerDarrell Bishop <darrell@swiftstack.com>2013-07-28 22:08:17 -0700
commit9198e95468b3005730c931da1701f34b1a9ce2d9 (patch)
treed6034f1a489b67273c19dc43221b142bd0c7bb65 /doc
parent5d9c6f845cc98da720fea7e2343fdbb0db9a42a5 (diff)
downloadpython-swiftclient-9198e95468b3005730c931da1701f34b1a9ce2d9.tar.gz
Move multi-threading code to a library.
This patch extracts the multi-threading code from bin/swift into swiftclient/multithreading and adds tests. In particular, this new way of doing it (with context managers) will prevent non-daemonic threads from wedging the process when unexpected exceptions happen. I enabled reporting of which lines, specifically, are not covered by unit tests (added -m option to "coverage report" in .unittests). This patch includes a drive-by fix for uploading a segmented file with --use-slo when that object already exists. A key of "name" was used instead of "path", raising KeyError. There's also another drive-by fix for uploading segmented objects with --use-slo. Commit 874e0e4427b80e1b15b74a1557b73ba9d61443ca regressed this by removing the capturing of thread-worker results in QueueFunctionThread.run(). This patch restores that functionality and the feature (uploading SLO objects). Change-Id: I0b4f677e4a734e83d1a25088d9a74f7d46384e53
Diffstat (limited to 'doc')
-rw-r--r--doc/source/conf.py7
-rw-r--r--doc/source/swiftclient.rst16
2 files changed, 14 insertions, 9 deletions
diff --git a/doc/source/conf.py b/doc/source/conf.py
index b1baab4..356b89e 100644
--- a/doc/source/conf.py
+++ b/doc/source/conf.py
@@ -15,8 +15,6 @@
import sys
import os
-import swiftclient
-
# If extensions (or modules to document with autodoc) are in another directory,
# add these directories to sys.path here. If the directory is relative to the
@@ -36,6 +34,9 @@ sys.path.insert(0, ROOT)
extensions = ['sphinx.ext.autodoc', 'sphinx.ext.doctest', 'sphinx.ext.todo',
'sphinx.ext.coverage']
+autoclass_content = 'both'
+autodoc_default_flags = ['members', 'undoc-members', 'show-inheritance']
+
# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']
@@ -50,7 +51,7 @@ master_doc = 'index'
# General information about the project.
project = u'Swiftclient'
-copyright = u'2012 OpenStack, LLC.'
+copyright = u'2013 OpenStack, LLC.'
# The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the
diff --git a/doc/source/swiftclient.rst b/doc/source/swiftclient.rst
index bc2bac8..8c5a020 100644
--- a/doc/source/swiftclient.rst
+++ b/doc/source/swiftclient.rst
@@ -4,14 +4,18 @@ swiftclient
==============
.. automodule:: swiftclient
- :members:
- :undoc-members:
- :show-inheritance:
swiftclient.client
==================
.. automodule:: swiftclient.client
- :members:
- :undoc-members:
- :show-inheritance:
+
+swiftclient.exceptions
+======================
+
+.. automodule:: swiftclient.exceptions
+
+swiftclient.multithreading
+==========================
+
+.. automodule:: swiftclient.multithreading