Web API, Web UI #86

Merged
projectmoon merged 37 commits from web-api into master 2021-07-15 15:04:54 +00:00
3 changed files with 105 additions and 551 deletions
Showing only changes of commit 7a59e6246f - Show all commits

648
Cargo.lock generated

File diff suppressed because it is too large Load Diff

View File

@ -9,13 +9,10 @@ log = "0.4"
tracing-subscriber = "0.2"
tonic = { version = "0.4" }
prost = "0.7"
once_cell = "1.7"
tenebrous-rpc = { path = "../rpc" }
juniper = { git = "https://github.com/graphql-rust/juniper", branch = "master" }
juniper_rocket_async = { git = "https://github.com/graphql-rust/juniper", branch = "master" }
rocket = { git = "https://github.com/SergioBenitez/Rocket", branch = "master" }
warp = "0.2"
#tokio-stream = { version = "0.1", features = ["net"] } # needed for grpc-web?
# [dependencies.tokio]
# version = "1"

View File

@ -1,12 +1,9 @@
use juniper::{
graphql_object, EmptyMutation, EmptySubscription, FieldError, FieldResult, GraphQLInputObject,
graphql_object, EmptyMutation, EmptySubscription, FieldResult, GraphQLInputObject,
GraphQLObject, RootNode,
};
use once_cell::sync::OnceCell;
use rocket::{response::content, Rocket, State};
use std::cell::RefCell;
use std::env;
use std::sync::{Arc, RwLock};
use tenebrous_rpc::protos::dicebot::dicebot_client::DicebotClient;
use tenebrous_rpc::protos::dicebot::GetVariableRequest;
use tonic::{metadata::MetadataValue, transport::Channel as TonicChannel, Request as TonicRequest};