From 098f7fba0362e278d53aa7a00c8a558e6de10d91 Mon Sep 17 00:00:00 2001 From: Quentin Gliech Date: Wed, 15 May 2024 14:26:37 +0200 Subject: [PATCH] Move async-graphql to workspace deps & disable apollo tracing --- Cargo.toml | 5 +++++ crates/graphql/Cargo.toml | 2 +- crates/handlers/Cargo.toml | 2 +- crates/handlers/src/graphql/mod.rs | 3 +-- 4 files changed, 8 insertions(+), 4 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index bc1b74b3..ca230b6f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -55,6 +55,11 @@ mas-templates = { path = "./crates/templates/", version = "=0.9.0" } mas-tower = { path = "./crates/tower/", version = "=0.9.0" } oauth2-types = { path = "./crates/oauth2-types/", version = "=0.9.0" } +# GraphQL server +[workspace.dependencies.async-graphql] +version = "6.0.11" +features = ["chrono", "url", "tracing"] + # Utility to write and implement async traits [workspace.dependencies.async-trait] version = "0.1.80" diff --git a/crates/graphql/Cargo.toml b/crates/graphql/Cargo.toml index cb462516..bba479c2 100644 --- a/crates/graphql/Cargo.toml +++ b/crates/graphql/Cargo.toml @@ -13,7 +13,7 @@ workspace = true [dependencies] anyhow.workspace = true -async-graphql = { version = "6.0.11", features = ["chrono", "url"] } +async-graphql.workspace = true async-trait.workspace = true chrono.workspace = true lettre.workspace = true diff --git a/crates/handlers/Cargo.toml b/crates/handlers/Cargo.toml index c0c41c00..1aa26da8 100644 --- a/crates/handlers/Cargo.toml +++ b/crates/handlers/Cargo.toml @@ -34,7 +34,7 @@ axum = "0.6.20" axum-macros = "0.3.8" axum-extra = { version = "0.8.0", features = ["cookie-private"] } -async-graphql = { version = "6.0.11", features = ["tracing", "apollo_tracing"] } +async-graphql.workspace = true # Emails lettre.workspace = true diff --git a/crates/handlers/src/graphql/mod.rs b/crates/handlers/src/graphql/mod.rs index 8d29f6d8..acdad738 100644 --- a/crates/handlers/src/graphql/mod.rs +++ b/crates/handlers/src/graphql/mod.rs @@ -15,7 +15,7 @@ use std::sync::Arc; use async_graphql::{ - extensions::{ApolloTracing, Tracing}, + extensions::Tracing, http::{playground_source, GraphQLPlaygroundConfig, MultipartOptions}, }; use axum::{ @@ -110,7 +110,6 @@ pub fn schema( mas_graphql::schema_builder() .extension(Tracing) - .extension(ApolloTracing) .data(state) .finish() }