rocksolid 2.7.0

An ergonomic, high-level RocksDB wrapper for Rust. Features CF-aware optimistic & pessimistic transactions, advanced routing for merge operators and compaction filters, performance tuning profiles, batching, TTL values, and DAO macros.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
use std::sync::Once;

static LOG_INIT: Once = Once::new();

pub fn setup_logging() {
  LOG_INIT.call_once(|| {
    env_logger::builder()
      .is_test(true)
      .try_init()
      .unwrap_or_else(|e| eprintln!("Failed to init logger: {}", e));
    // Using try_init().unwrap_or_else(...) because init() will panic if called more than once.
    // is_test(true) often configures it to write to stdout for tests.
  });
}