summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--doc/api/librbdpy.rst7
1 files changed, 4 insertions, 3 deletions
diff --git a/doc/api/librbdpy.rst b/doc/api/librbdpy.rst
index 2c57fd55ecd..da823c7fdd4 100644
--- a/doc/api/librbdpy.rst
+++ b/doc/api/librbdpy.rst
@@ -61,9 +61,10 @@ block::
finally:
cluster.shutdown()
-This can be cumbersome, so the :class:Rados, :class:Ioctx, and :class:Image
-classes can be used as context managers that close/shutdown automatically (see
-:pep:`343`). Using them as context managers, the above example becomes::
+This can be cumbersome, so the :class:`Rados`, :class:`Ioctx`, and
+:class:`Image` classes can be used as context managers that close/shutdown
+automatically (see :pep:`343`). Using them as context managers, the
+above example becomes::
with rados.Rados(conffile='my_ceph.conf') as cluster:
with cluster.open_ioctx('mypool') as ioctx: