11 unstable releases
Uses old Rust 2015
0.6.0 | Jan 7, 2021 |
---|---|
0.5.0 | Dec 28, 2019 |
0.4.0 | Aug 25, 2019 |
0.3.0 | Jan 4, 2019 |
0.1.0 | Jan 18, 2017 |
#77 in #connection-pool
256 downloads per month
Used in 4 crates
(3 directly)
1MB
1.5K
SLoC
Contains (WOFF font, 120KB) target/doc/Heuristica-Italic.woff, (WOFF font, 90KB) target/doc/FiraSans-Medium.woff, (WOFF font, 92KB) target/doc/FiraSans-Regular.woff, (WOFF font, 56KB) target/doc/SourceCodePro-Regular.woff, (WOFF font, 56KB) target/doc/SourceCodePro-Semibold.woff, (WOFF font, 49KB) target/doc/SourceSerifPro-Bold.woff and 1 more.
r2d2-memcache
Install
Add this to your Cargo.toml
:
[dependencies]
r2d2-memcache = "0.2.0"
Basic Usage
extern crate r2d2_memcache;
fn main() {
let manager = r2d2_memcache::MemcacheConnectionManager::new("memcache://localhost:11211");
let pool = r2d2_memcache::r2d2::Pool::builder().max_size(15).build(manager).unwrap();
let mut conn = pool.get().unwrap();
conn.flush().unwrap();
let value = "bar";
conn.set("foo_get", value, 10).unwrap();
let result: String = conn.get("foo_get").unwrap().unwrap();
assert!(result == "bar");
}
License
- MIT license (LICENSE-MIT or http://opensource.org/licenses/MIT)
- This software includes the work that is distributed in the Apache License 2.0
Dependencies
~3–9MB
~80K SLoC