Class HttpRequestHeaderInterceptor

java.lang.Object
org.springframework.graphql.server.support.HttpRequestHeaderInterceptor
All Implemented Interfaces:
WebGraphQlInterceptor

public final class HttpRequestHeaderInterceptor extends Object implements WebGraphQlInterceptor
Interceptor that copies HTTP request headers to the GraphQL context to make them available to data fetchers such as annotated controllers, which can use @ContextValue method parameters to access the headers as context values.

User builder() to build an instance, and specify headers of interest that should be copied to the GraphQL context.

Since:
2.0.0
Author:
Rossen Stoyanchev