An rpc server implementation using msgpack
You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
trivernis 8b8245b6b8
Add license and crates.io metadata
Signed-off-by: trivernis <trivernis@protonmail.com>
4 years ago
src Add scheduled thread pool 4 years ago
.gitignore Add Message struct and implementation 4 years ago
Cargo.toml Add license and crates.io metadata 4 years ago
LICENSE Add license and crates.io metadata 4 years ago
README.md Update README 4 years ago

README.md

msg-rpc

An rpc server implementation using msgpack

Usage

Add the crate to the dependencies

[dependencies]
msgrpc = {git = "https://github.com/flotte-goes-smart/msg-rpc/tree/main"}
pub fn main() {
    let mut server = RPCServer::new("127.0.0.1:".to_string());
    let mut receiver = Arc::clone(&server.receiver);
    thread::spawn(move || {
        server.start();        
    });
    for handler in receiver {
        // handle the message and return a response
    }
}