Skip to navigation
Actix-storage
12.09.22
use actix_storage::{Format, Storage}; let store = actix_storage_hashmap::HashMapStore::new(); let storage = Storage::build().store(store).format(Format::Json).finish(); storage.set_bytes("key", "hellox").await; let val = storage.get_bytes("key").await.unwrap().unwrap(); println!("{:?}",str::from_utf8(&val).unwrap()); storage.set_bytes("key", "helloxx").await; let val = storage.get_bytes("key").await.unwrap().unwrap(); println!("{:?}",str::from_utf8(&val).unwrap()); storage.set_bytes("host", s_host).await; let val = storage.get_bytes("host").await.unwrap().unwrap(); println!("host:{:?}",str::from_utf8(&val).unwrap());
https://github.com/pooyamb/actix-storage
Reply
Anonymous
Information Epoch 1732476972
Design for visibility.
Home
Notebook
Contact us