From 5b5ff7f1a165c2a4536690f43ae095f21da8c265 Mon Sep 17 00:00:00 2001 From: angrykoala Date: Fri, 14 Mar 2025 14:34:41 +0000 Subject: [PATCH 1/2] Add aggregate to migration guide deprecations --- modules/ROOT/pages/migration/index.adoc | 41 +++++++++++++++++++++++++ 1 file changed, 41 insertions(+) diff --git a/modules/ROOT/pages/migration/index.adoc b/modules/ROOT/pages/migration/index.adoc index 40bb46a5..b128e60d 100644 --- a/modules/ROOT/pages/migration/index.adoc +++ b/modules/ROOT/pages/migration/index.adoc @@ -564,3 +564,44 @@ A warning is raised if you use a deprecated value. === Deprecated aggregations on ID fields Aggregations on ID fields are now deprecated and will be removed in the future. + + +=== Deprecated Aggregate operations + +Explicit Aggregate operations, both top level and nested, have been deprecated in favor of the fields `aggregate` inside Connection operations. + +So, for example: + +[source, graphql, indent=0] +---- +query { + moviesAggregate { + count + title { + shortest + } + } +} +---- + +Is deprecated in favor of: + +[source, graphql, indent=0] +---- +query { + moviesConnection { + aggregate { + node { + title { + shortest + } + } + count { + nodes + } + } + } +} +---- + +Note that `count` now returns the explcit fields `nodes` and `edges`. From 5db7766d408c2678469c3380d4b94bb94c3b8495 Mon Sep 17 00:00:00 2001 From: angrykoala Date: Tue, 18 Mar 2025 11:04:19 +0000 Subject: [PATCH 2/2] Apply suggestions from code review Co-authored-by: Richard Sill <156673635+rsill-neo4j@users.noreply.github.com> --- modules/ROOT/pages/migration/index.adoc | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/modules/ROOT/pages/migration/index.adoc b/modules/ROOT/pages/migration/index.adoc index b128e60d..20c90c18 100644 --- a/modules/ROOT/pages/migration/index.adoc +++ b/modules/ROOT/pages/migration/index.adoc @@ -566,11 +566,11 @@ A warning is raised if you use a deprecated value. Aggregations on ID fields are now deprecated and will be removed in the future. -=== Deprecated Aggregate operations +=== Deprecated aggregation operations -Explicit Aggregate operations, both top level and nested, have been deprecated in favor of the fields `aggregate` inside Connection operations. +Explicit aggregation operations, both top-level and nested, have been deprecated in favor of the `aggregate` field inside connection operations. -So, for example: +For example: [source, graphql, indent=0] ---- @@ -584,7 +584,7 @@ query { } ---- -Is deprecated in favor of: +The previous query is deprecated in favor of the following: [source, graphql, indent=0] ---- @@ -604,4 +604,4 @@ query { } ---- -Note that `count` now returns the explcit fields `nodes` and `edges`. +Note that `count` now returns the explicit fields `nodes` and `edges`.