diff --git a/.changesets/fix_lrlna_update_apollo_compiler.md b/.changesets/fix_lrlna_update_apollo_compiler.md new file mode 100644 index 0000000000..75653b4343 --- /dev/null +++ b/.changesets/fix_lrlna_update_apollo_compiler.md @@ -0,0 +1,8 @@ +### Use less recursion in GraphQL parser ([Issue #4142](https://github.com/apollographql/router/issues/4142)) + +This updates the Router with the latest `apollo-parser` version, +which removes unnecessary use of recursion for parsing repeated syntax elements +such as enum values and union members in type definitions. +Some documents that used to hit the parser’s recursion limit will now successfully parse. + +By [@lrlna](https://github.com/lrlna) in https://github.com/apollographql/router/pull/4167 diff --git a/Cargo.lock b/Cargo.lock index 46dbc17375..ac9fdcfce9 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -217,11 +217,11 @@ dependencies = [ [[package]] name = "apollo-compiler" -version = "1.0.0-beta.4" +version = "1.0.0-beta.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a5ff474a85ea7b22c944aba74bab8863366adde503d00864d01da2284c670aa8" +checksum = "1ae76a91725ab7ecd35d552db3fb3d3b3f534a4520330920a58a39892174b7ae" dependencies = [ - "apollo-parser 0.7.1", + "apollo-parser 0.7.3", "ariadne", "indexmap 2.0.2", "rowan", @@ -245,11 +245,11 @@ dependencies = [ [[package]] name = "apollo-federation" -version = "0.0.1" +version = "0.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38d08d88375b1cb778d4b663877fa5d2ba482180283d2071f4de75e697627d60" +checksum = "6deb778a0fbd1448bffb6ebf8d33d8719ffda3f785482ddd7c26d0c72fc243d2" dependencies = [ - "apollo-compiler 1.0.0-beta.4", + "apollo-compiler 1.0.0-beta.5", "indexmap 2.0.2", "lazy_static", "salsa", @@ -272,9 +272,9 @@ dependencies = [ [[package]] name = "apollo-parser" -version = "0.7.1" +version = "0.7.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c382f531987366a6954ac687305652b1428b049ca1294b4502b0a9dbbf0d37b8" +checksum = "7bb81e4793effa1744cc96f49542aec487696e595e0faeabbd9f8a83e5c83036" dependencies = [ "memchr", "rowan", @@ -287,7 +287,7 @@ version = "1.33.2" dependencies = [ "access-json", "anyhow", - "apollo-compiler 1.0.0-beta.4", + "apollo-compiler 1.0.0-beta.5", "apollo-federation", "arc-swap", "askama", @@ -6372,7 +6372,7 @@ name = "supergraph_sdl" version = "0.1.0" dependencies = [ "anyhow", - "apollo-compiler 1.0.0-beta.4", + "apollo-compiler 1.0.0-beta.5", "apollo-router", "async-trait", "tower", @@ -7431,9 +7431,9 @@ checksum = "711b9620af191e0cdc7468a8d14e709c3dcdb115b36f838e601583af800a370a" [[package]] name = "uuid" -version = "1.4.1" +version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "79daa5ed5740825c40b389c5e50312b9c86df53fccd33f281df655642b43869d" +checksum = "88ad59a7560b41a70d191093a945f0b87bc1deeda46fb237479708a1d6b6cdfc" dependencies = [ "getrandom 0.2.10", "serde", diff --git a/apollo-router/Cargo.toml b/apollo-router/Cargo.toml index 6902c65a97..ce8a4e6abc 100644 --- a/apollo-router/Cargo.toml +++ b/apollo-router/Cargo.toml @@ -57,8 +57,8 @@ features = ["docs_rs"] askama = "0.12.1" access-json = "0.1.0" anyhow = "1.0.75" -apollo-compiler = "=1.0.0-beta.4" -apollo-federation = "0.0.1" +apollo-compiler = "=1.0.0-beta.5" +apollo-federation = "0.0.3" arc-swap = "1.6.0" async-compression = { version = "0.4.4", features = [ "tokio", diff --git a/examples/supergraph-sdl/rust/Cargo.toml b/examples/supergraph-sdl/rust/Cargo.toml index 06fe186d26..f95056482e 100644 --- a/examples/supergraph-sdl/rust/Cargo.toml +++ b/examples/supergraph-sdl/rust/Cargo.toml @@ -5,7 +5,7 @@ edition = "2021" [dependencies] anyhow = "1" -apollo-compiler = "=1.0.0-beta.4" +apollo-compiler = "=1.0.0-beta.5" apollo-router = { path = "../../../apollo-router" } async-trait = "0.1" tower = { version = "0.4", features = ["full"] }