Skip to content

Commit e4bc915

Browse files
chore(graphql): bump graphql engine version (#9864)
1 parent cda34b5 commit e4bc915

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

build.gradle

+2-2
Original file line numberDiff line numberDiff line change
@@ -128,8 +128,8 @@ project.ext.externalDependency = [
128128
'elasticSearchRest': 'org.opensearch.client:opensearch-rest-high-level-client:' + elasticsearchVersion,
129129
'elasticSearchJava': 'org.opensearch.client:opensearch-java:2.6.0',
130130
'findbugsAnnotations': 'com.google.code.findbugs:annotations:3.0.1',
131-
'graphqlJava': 'com.graphql-java:graphql-java:19.5',
132-
'graphqlJavaScalars': 'com.graphql-java:graphql-java-extended-scalars:19.1',
131+
'graphqlJava': 'com.graphql-java:graphql-java:21.3',
132+
'graphqlJavaScalars': 'com.graphql-java:graphql-java-extended-scalars:21.0',
133133
'gson': 'com.google.code.gson:gson:2.8.9',
134134
'guice': 'com.google.inject:guice:7.0.0',
135135
'guice4': 'com.google.inject:guice:4.2.3', // Used for frontend while still on old Play version

datahub-graphql-core/src/main/java/com/linkedin/datahub/graphql/exception/DataHubDataFetcherExceptionHandler.java

+4-2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
import graphql.execution.DataFetcherExceptionHandlerResult;
77
import graphql.execution.ResultPath;
88
import graphql.language.SourceLocation;
9+
import java.util.concurrent.CompletableFuture;
910
import lombok.extern.slf4j.Slf4j;
1011

1112
@PublicApi
@@ -15,7 +16,7 @@ public class DataHubDataFetcherExceptionHandler implements DataFetcherExceptionH
1516
private static final String DEFAULT_ERROR_MESSAGE = "An unknown error occurred.";
1617

1718
@Override
18-
public DataFetcherExceptionHandlerResult onException(
19+
public CompletableFuture<DataFetcherExceptionHandlerResult> handleException(
1920
DataFetcherExceptionHandlerParameters handlerParameters) {
2021
Throwable exception = handlerParameters.getException();
2122
SourceLocation sourceLocation = handlerParameters.getSourceLocation();
@@ -44,7 +45,8 @@ public DataFetcherExceptionHandlerResult onException(
4445
log.error("Failed to execute", exception);
4546
}
4647
DataHubGraphQLError error = new DataHubGraphQLError(message, path, sourceLocation, errorCode);
47-
return DataFetcherExceptionHandlerResult.newResult().error(error).build();
48+
return CompletableFuture.completedFuture(
49+
DataFetcherExceptionHandlerResult.newResult().error(error).build());
4850
}
4951

5052
<T extends Throwable> T findFirstThrowableCauseOfClass(Throwable throwable, Class<T> clazz) {

0 commit comments

Comments
 (0)