Client API
let client = MultiplexedClient::connect("127.0.0.1:7777").await?;
let (a, b, c) = tokio::join!(
client.get("key-one"),
client.set("key-two", b"value"),
client.delete("key-three"),
);
let mut handles = JoinSet::new();
for i in 0..1000 {
let c = client.clone();
handles.spawn(async move { c.get(&format!("k{}", i)).await });
}
while let Some(r) = handles.join_next().await {
r.unwrap().unwrap();
}