Gql direct execution - Improvements (#18972)
#### Direct Execution __typename & null backfill ##### __typename filling The direct execution path now correctly derives __typename at every level of the GraphQL response: Connection types — CompanyConnection, CompanyEdge, Company, PageInfo GroupBy types — TaskGroupByConnection (was incorrectly producing TaskConnection) Composite fields — Links, FullName, Currency, etc. handled by a dedicated formatter (was inheriting the parent object's typename) Previously, __typename was derived from the object's universal identifier (a UUID), producing broken values like 20202020B3744779A56180086Cb2E17FConnection. ##### Null backfill Selected fields missing from the resolver result are backfilled with null, matching the standard Yoga schema behavior. ##### Integration test A new test runs the same findMany query (with __typename at all structural levels) through both paths — standard Yoga schema and direct execution — and asserts identical output via toStrictEqual.
This commit is contained in:
+11
@@ -0,0 +1,11 @@
|
||||
import { RESOLVER_METHOD_NAMES } from 'src/engine/api/graphql/workspace-resolver-builder/constants/resolver-method-names';
|
||||
|
||||
export const CONNECTION_METHOD_NAMES = new Set<string>([
|
||||
RESOLVER_METHOD_NAMES.FIND_MANY,
|
||||
RESOLVER_METHOD_NAMES.FIND_DUPLICATES,
|
||||
RESOLVER_METHOD_NAMES.CREATE_MANY,
|
||||
RESOLVER_METHOD_NAMES.UPDATE_MANY,
|
||||
RESOLVER_METHOD_NAMES.DELETE_MANY,
|
||||
RESOLVER_METHOD_NAMES.DESTROY_MANY,
|
||||
RESOLVER_METHOD_NAMES.RESTORE_MANY,
|
||||
]);
|
||||
Reference in New Issue
Block a user