dbus-router 0.4.1

A dual-upstream D-Bus router library
Documentation

D-Bus Router Library

A dual-upstream D-Bus router that can route messages to different buses based on destination matching rules.

Example

use dbus_router::{Config, Router};
use std::path::PathBuf;

#[tokio::main]
async fn main() -> anyhow::Result<()> {
    let config = Config::default();
    let router = Router::new(
        PathBuf::from("/tmp/proxy.sock"),
        "unix:path=/run/user/1000/bus".to_string(),
        "unix:path=/tmp/sandbox.sock".to_string(),
        config,
    );
    router.run().await
}