Function foundationdb::default_api
source · pub fn default_api() -> Result<NetworkBuilder>
Expand description
Initialize the FoundationDB Client API, this can only be called once per process.
Returns
A NetworkBuilder
which can be used to configure the FoundationDB Client API Network.
Example
use foundationdb;
use foundationdb::options::NetworkOption;
let network = foundationdb::default_api()
.expect("failed to initialize API version")
.set_option(NetworkOption::DisableClientStatisticsLogging)
.expect("failed to set option")
.build()
.expect("failed to initialize network");
// see example on `init`