Skip to content

Commit

Permalink
Upgrade to GraphQL Java 22 test version
Browse files Browse the repository at this point in the history
This commit upgrades GraphQL Java to
"0.0.0-2024-03-20T00-25-33-974c165", a test version for the upcoming
22.0 release.

See gh-932
  • Loading branch information
bclozel committed Mar 21, 2024
1 parent 3da533d commit 2f98403
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ description = "Spring for GraphQL"
ext {
moduleProjects = [project(":spring-graphql"), project(":spring-graphql-test")]
springFrameworkVersion = "6.1.4"
graphQlJavaVersion = "21.3"
graphQlJavaVersion = "0.0.0-2024-03-20T00-25-33-974c165"
springBootVersion = "3.2.2"
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
import graphql.GraphQL;
import graphql.GraphQLContext;
import graphql.execution.ExecutionIdProvider;
import graphql.execution.instrumentation.dataloader.DataLoaderDispatcherInstrumentationState;
import graphql.execution.instrumentation.dataloader.EmptyDataLoaderRegistryInstance;
import io.micrometer.context.ContextSnapshotFactory;
import org.dataloader.DataLoaderRegistry;
import reactor.core.publisher.Mono;
Expand Down Expand Up @@ -90,7 +90,6 @@ public final Mono<ExecutionGraphQlResponse> execute(ExecutionGraphQlRequest requ

ExecutionInput executionInput = request.toExecutionInput();

GraphQLContext graphQLContext = executionInput.getGraphQLContext();
snapshotFactory.captureFrom(contextView).updateContext(executionInput.getGraphQLContext());

ExecutionInput updatedExecutionInput =
Expand All @@ -104,7 +103,7 @@ public final Mono<ExecutionGraphQlResponse> execute(ExecutionGraphQlRequest requ
private ExecutionInput registerDataLoaders(ExecutionInput executionInput) {
GraphQLContext graphQLContext = executionInput.getGraphQLContext();
DataLoaderRegistry existingRegistry = executionInput.getDataLoaderRegistry();
if (existingRegistry == DataLoaderDispatcherInstrumentationState.EMPTY_DATALOADER_REGISTRY) {
if (existingRegistry == EmptyDataLoaderRegistryInstance.EMPTY_DATALOADER_REGISTRY) {
DataLoaderRegistry newRegistry = DataLoaderRegistry.newRegistry().build();
applyDataLoaderRegistrars(newRegistry, graphQLContext);
executionInput = executionInput.transform(builder -> builder.dataLoaderRegistry(newRegistry));
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright 2002-2023 the original author or authors.
* Copyright 2002-2024 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -161,7 +161,7 @@ public static abstract class Builder<B extends Builder<B, R>, R extends Executio

private final R original;

private final ExecutionResultImpl.Builder executionResultBuilder;
private final ExecutionResultImpl.Builder<?> executionResultBuilder;

protected Builder(R original) {
this.original = original;
Expand Down

0 comments on commit 2f98403

Please sign in to comment.