FG
๐Ÿ’ป Software๐Ÿ”Œ APIs & SDKs

GraphQL doing unnecessary/repetitious requests/resolves.

Freshover 10 years ago
Mar 14, 20260 views
Confidence Score88%
88%

Problem

Hi, Given the following type language schema: [code block] and the following query: [code block] we see the following requests for data on the backend: [code block] [uids are generated per unique call to `resolve`]. These repetitious requests came as a surprise given that one of GraphQL's biggest selling points is the elimination of N+1 queries and the introduction of intelligent caching/simplification/reduction etc etc etc Is this a known issue?

Unverified for your environment

Select your OS to check compatibility.

1 Fix

Canonical Fix
Moderate Confidence Fix
84% confidence100% success rate2 verificationsLast verified Mar 14, 2026

Solution: GraphQL doing unnecessary/repetitious requests/resolves.

Low Risk

The biggest problems with optimization currently is that not all parts of the tree are known beforehand, eg due to the way typed fragments work with interface or union resolving. We did this full optimization before graphql-js was released, but we lacked such features in our type system. I believe that it's possible to do some optimization beforehand, though, but I think a more reliable solution a

84

Trust Score

2 verifications

100% success
  1. 1

    The biggest problems with optimization currently is that not all parts of the tr

    The biggest problems with optimization currently is that not all parts of the tree are known beforehand, eg due to the way typed fragments work with interface or union resolving. We did this full optimization before graphql-js was released, but we lacked such features in our type system. I believe that it's possible to do some optimization beforehand, though, but I think a more reliable solution at this point is optimization through a query proxy, like described, eg, here https://www.reddit.com/r/reactjs/comments/3flgnu/building_a_graphql_server_with_nodejs_and_sql/ctqudkn

  2. 2

    On Thu, Aug 27, 2015 at 10:19 PM, Lee Byron notifications@github.com

    wrote:

  3. 3

    > To be clear - I'm not saying that GraphQL _should not_ contain these optimizat

    > > Reply to this email directly or view it on GitHub: > https://github.com/graphql/graphql-js/issues/111#issuecomment-135528516

Validation

Resolved in graphql/graphql-js GitHub issue #111. Community reactions: 1 upvotes.

Verification Summary

Worked: 2
Last verified Mar 14, 2026

Sign in to verify this fix

Environment

Submitted by

AC

Alex Chen

2450 rep

Tags

graphqlapischema