Module rad::rados [] [src]

Wrappers for Ceph cluster connections, Ceph I/O contexts, and associated operations.

Connection building example

The following example connects to a Ceph cluster using the ceph.conf file at /etc/ceph/ceph.conf, as the admin user, and setting the RADOS config keyring option to the value of /etc/ceph/ceph.client.admin.keyring (which is necessary for connecting to Ceph using config files/keyrings located on nonstandard paths.)

use std::path::Path;
use rad::ConnectionBuilder;

let mut cluster = ConnectionBuilder::with_user("admin")?
                  .read_conf_file(Path::new("/etc/ceph/ceph.conf"))?
                  .conf_set("keyring", "/etc/ceph/ceph.client.admin.keyring")?
                  .connect()?;

Structs

ClusterStat

Statistics for a Ceph cluster: total storage in kilobytes, the amount of storage used in kilobytes, the amount of available storage in kilobytes, and the number of stored objects.

Connection

A wrapper over a connection to a Ceph cluster.

ConnectionBuilder

A wrapper around a rados_t providing methods for configuring the connection before finalizing it.

Context

A wrapper around a rados_ioctx_t, which also counts as a reference to the underlying Connection.

DataFuture
ExistsFuture
ReadFuture
Stat

Statistics for a single RADOS object.

StatFuture
UnitFuture

The type of a RADOS AIO operation which has yet to complete.