raphtory-graphql 0.11.1

Raphtory GraphQL server
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
use raphtory_graphql::GraphServer;
use std::{
    env,
    path::{Path, PathBuf},
};
use tokio::io::Result as IoResult;

#[tokio::main]
async fn main() -> IoResult<()> {
    let default_path = Path::new("/tmp/graphs");
    let work_dir = env::var("GRAPH_DIRECTORY").unwrap_or(default_path.display().to_string());
    let work_dir = PathBuf::from(&work_dir);

    GraphServer::new(work_dir, None, None)?.run().await?;

    Ok(())
}