Create spring-boot-graphql module

This commit is contained in:
Andy Wilkinson 2025-04-04 17:15:43 +01:00
parent 45cea6281c
commit 36c28c9ac7
56 changed files with 186 additions and 137 deletions

View File

@ -72,6 +72,7 @@ include "spring-boot-project:spring-boot-docs"
include "spring-boot-project:spring-boot-elasticsearch" include "spring-boot-project:spring-boot-elasticsearch"
include "spring-boot-project:spring-boot-flyway" include "spring-boot-project:spring-boot-flyway"
include "spring-boot-project:spring-boot-freemarker" include "spring-boot-project:spring-boot-freemarker"
include "spring-boot-project:spring-boot-graphql"
include "spring-boot-project:spring-boot-groovy-templates" include "spring-boot-project:spring-boot-groovy-templates"
include "spring-boot-project:spring-boot-gson" include "spring-boot-project:spring-boot-gson"
include "spring-boot-project:spring-boot-h2console" include "spring-boot-project:spring-boot-h2console"

View File

@ -134,7 +134,6 @@ dependencies {
optional("org.springframework.data:spring-data-jdbc") optional("org.springframework.data:spring-data-jdbc")
optional("org.springframework.data:spring-data-mongodb") optional("org.springframework.data:spring-data-mongodb")
optional("org.springframework.data:spring-data-r2dbc") optional("org.springframework.data:spring-data-r2dbc")
optional("org.springframework.graphql:spring-graphql")
optional("org.springframework.hateoas:spring-hateoas") optional("org.springframework.hateoas:spring-hateoas")
optional("org.springframework.security:spring-security-acl") optional("org.springframework.security:spring-security-acl")
optional("org.springframework.security:spring-security-config") optional("org.springframework.security:spring-security-config")
@ -183,7 +182,6 @@ dependencies {
testImplementation("org.junit.jupiter:junit-jupiter") testImplementation("org.junit.jupiter:junit-jupiter")
testImplementation("org.postgresql:postgresql") testImplementation("org.postgresql:postgresql")
testImplementation("org.postgresql:r2dbc-postgresql") testImplementation("org.postgresql:r2dbc-postgresql")
testImplementation("org.springframework.graphql:spring-graphql-test")
testImplementation("org.springframework.security:spring-security-test") testImplementation("org.springframework.security:spring-security-test")
testImplementation("org.yaml:snakeyaml") testImplementation("org.yaml:snakeyaml")

View File

@ -19,14 +19,6 @@
"description": "Whether to enable the PersistenceExceptionTranslationPostProcessor.", "description": "Whether to enable the PersistenceExceptionTranslationPostProcessor.",
"defaultValue": true "defaultValue": true
}, },
{
"name": "spring.graphql.schema.file-extensions",
"defaultValue": ".graphqls,.gqls"
},
{
"name": "spring.graphql.schema.locations",
"defaultValue": "classpath:graphql/**/"
},
{ {
"name": "spring.http.encoding.charset", "name": "spring.http.encoding.charset",
"type": "java.nio.charset.Charset", "type": "java.nio.charset.Charset",

View File

@ -1,16 +1,5 @@
org.springframework.boot.autoconfigure.aop.AopAutoConfiguration org.springframework.boot.autoconfigure.aop.AopAutoConfiguration
org.springframework.boot.autoconfigure.dao.PersistenceExceptionTranslationAutoConfiguration org.springframework.boot.autoconfigure.dao.PersistenceExceptionTranslationAutoConfiguration
org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration
org.springframework.boot.autoconfigure.graphql.data.GraphQlReactiveQueryByExampleAutoConfiguration
org.springframework.boot.autoconfigure.graphql.data.GraphQlReactiveQuerydslAutoConfiguration
org.springframework.boot.autoconfigure.graphql.data.GraphQlQueryByExampleAutoConfiguration
org.springframework.boot.autoconfigure.graphql.data.GraphQlQuerydslAutoConfiguration
org.springframework.boot.autoconfigure.graphql.reactive.GraphQlWebFluxAutoConfiguration
org.springframework.boot.autoconfigure.graphql.rsocket.GraphQlRSocketAutoConfiguration
org.springframework.boot.autoconfigure.graphql.rsocket.RSocketGraphQlClientAutoConfiguration
org.springframework.boot.autoconfigure.graphql.security.GraphQlWebFluxSecurityAutoConfiguration
org.springframework.boot.autoconfigure.graphql.security.GraphQlWebMvcSecurityAutoConfiguration
org.springframework.boot.autoconfigure.graphql.servlet.GraphQlWebMvcAutoConfiguration
org.springframework.boot.autoconfigure.http.client.HttpClientAutoConfiguration org.springframework.boot.autoconfigure.http.client.HttpClientAutoConfiguration
org.springframework.boot.autoconfigure.http.client.reactive.ClientHttpConnectorAutoConfiguration org.springframework.boot.autoconfigure.http.client.reactive.ClientHttpConnectorAutoConfiguration
org.springframework.boot.autoconfigure.netty.NettyAutoConfiguration org.springframework.boot.autoconfigure.netty.NettyAutoConfiguration

View File

@ -79,6 +79,7 @@ dependencies {
autoConfiguration(project(path: ":spring-boot-project:spring-boot-elasticsearch", configuration: "autoConfigurationMetadata")) autoConfiguration(project(path: ":spring-boot-project:spring-boot-elasticsearch", configuration: "autoConfigurationMetadata"))
autoConfiguration(project(path: ":spring-boot-project:spring-boot-flyway", configuration: "autoConfigurationMetadata")) autoConfiguration(project(path: ":spring-boot-project:spring-boot-flyway", configuration: "autoConfigurationMetadata"))
autoConfiguration(project(path: ":spring-boot-project:spring-boot-freemarker", configuration: "autoConfigurationMetadata")) autoConfiguration(project(path: ":spring-boot-project:spring-boot-freemarker", configuration: "autoConfigurationMetadata"))
autoConfiguration(project(path: ":spring-boot-project:spring-boot-graphql", configuration: "autoConfigurationMetadata"))
autoConfiguration(project(path: ":spring-boot-project:spring-boot-gson", configuration: "autoConfigurationMetadata")) autoConfiguration(project(path: ":spring-boot-project:spring-boot-gson", configuration: "autoConfigurationMetadata"))
autoConfiguration(project(path: ":spring-boot-project:spring-boot-h2console", configuration: "autoConfigurationMetadata")) autoConfiguration(project(path: ":spring-boot-project:spring-boot-h2console", configuration: "autoConfigurationMetadata"))
autoConfiguration(project(path: ":spring-boot-project:spring-boot-hateoas", configuration: "autoConfigurationMetadata")) autoConfiguration(project(path: ":spring-boot-project:spring-boot-hateoas", configuration: "autoConfigurationMetadata"))
@ -155,6 +156,7 @@ dependencies {
configurationProperties(project(path: ":spring-boot-project:spring-boot-elasticsearch", configuration: "configurationPropertiesMetadata")) configurationProperties(project(path: ":spring-boot-project:spring-boot-elasticsearch", configuration: "configurationPropertiesMetadata"))
configurationProperties(project(path: ":spring-boot-project:spring-boot-flyway", configuration: "configurationPropertiesMetadata")) configurationProperties(project(path: ":spring-boot-project:spring-boot-flyway", configuration: "configurationPropertiesMetadata"))
configurationProperties(project(path: ":spring-boot-project:spring-boot-freemarker", configuration: "configurationPropertiesMetadata")) configurationProperties(project(path: ":spring-boot-project:spring-boot-freemarker", configuration: "configurationPropertiesMetadata"))
configurationProperties(project(path: ":spring-boot-project:spring-boot-graphql", configuration: "configurationPropertiesMetadata"))
configurationProperties(project(path: ":spring-boot-project:spring-boot-gson", configuration: "configurationPropertiesMetadata")) configurationProperties(project(path: ":spring-boot-project:spring-boot-gson", configuration: "configurationPropertiesMetadata"))
configurationProperties(project(path: ":spring-boot-project:spring-boot-h2console", configuration: "configurationPropertiesMetadata")) configurationProperties(project(path: ":spring-boot-project:spring-boot-h2console", configuration: "configurationPropertiesMetadata"))
configurationProperties(project(path: ":spring-boot-project:spring-boot-hateoas", configuration: "configurationPropertiesMetadata")) configurationProperties(project(path: ":spring-boot-project:spring-boot-hateoas", configuration: "configurationPropertiesMetadata"))

View File

@ -426,7 +426,7 @@ There are javadoc:org.springframework.graphql.test.tester.GraphQlTester[] varian
Spring Boot helps you to test your {url-spring-graphql-docs}/controllers.html[Spring GraphQL Controllers] with the javadoc:org.springframework.boot.test.autoconfigure.graphql.GraphQlTest[format=annotation] annotation. Spring Boot helps you to test your {url-spring-graphql-docs}/controllers.html[Spring GraphQL Controllers] with the javadoc:org.springframework.boot.test.autoconfigure.graphql.GraphQlTest[format=annotation] annotation.
javadoc:org.springframework.boot.test.autoconfigure.graphql.GraphQlTest[format=annotation] auto-configures the Spring GraphQL infrastructure, without any transport nor server being involved. javadoc:org.springframework.boot.test.autoconfigure.graphql.GraphQlTest[format=annotation] auto-configures the Spring GraphQL infrastructure, without any transport nor server being involved.
This limits scanned beans to javadoc:org.springframework.stereotype.Controller[format=annotation], javadoc:org.springframework.graphql.execution.RuntimeWiringConfigurer[], javadoc:org.springframework.boot.jackson.JsonComponent[], javadoc:org.springframework.core.convert.converter.Converter[], javadoc:org.springframework.core.convert.converter.GenericConverter[], javadoc:org.springframework.graphql.execution.DataFetcherExceptionResolver[], javadoc:graphql.execution.instrumentation.Instrumentation[] and javadoc:org.springframework.boot.autoconfigure.graphql.GraphQlSourceBuilderCustomizer[]. This limits scanned beans to javadoc:org.springframework.stereotype.Controller[format=annotation], javadoc:org.springframework.graphql.execution.RuntimeWiringConfigurer[], javadoc:org.springframework.boot.jackson.JsonComponent[], javadoc:org.springframework.core.convert.converter.Converter[], javadoc:org.springframework.core.convert.converter.GenericConverter[], javadoc:org.springframework.graphql.execution.DataFetcherExceptionResolver[], javadoc:graphql.execution.instrumentation.Instrumentation[] and javadoc:org.springframework.boot.graphql.autoconfigure.GraphQlSourceBuilderCustomizer[].
Regular javadoc:org.springframework.stereotype.Component[format=annotation] and javadoc:org.springframework.boot.context.properties.ConfigurationProperties[format=annotation] beans are not scanned when the javadoc:org.springframework.boot.test.autoconfigure.graphql.GraphQlTest[format=annotation] annotation is used. Regular javadoc:org.springframework.stereotype.Component[format=annotation] and javadoc:org.springframework.boot.context.properties.ConfigurationProperties[format=annotation] beans are not scanned when the javadoc:org.springframework.boot.test.autoconfigure.graphql.GraphQlTest[format=annotation] annotation is used.
javadoc:org.springframework.boot.context.properties.EnableConfigurationProperties[format=annotation] can be used to include javadoc:org.springframework.boot.context.properties.ConfigurationProperties[format=annotation] beans. javadoc:org.springframework.boot.context.properties.EnableConfigurationProperties[format=annotation] can be used to include javadoc:org.springframework.boot.context.properties.ConfigurationProperties[format=annotation] beans.

View File

@ -0,0 +1,40 @@
plugins {
id "java-library"
id "org.springframework.boot.auto-configuration"
id "org.springframework.boot.configuration-properties"
id "org.springframework.boot.deployed"
id "org.springframework.boot.optional-dependencies"
}
description = "Spring Boot GraphQL"
dependencies {
api(project(":spring-boot-project:spring-boot"))
api("org.springframework.graphql:spring-graphql")
implementation(project(":spring-boot-project:spring-boot-jackson"))
optional(project(":spring-boot-project:spring-boot-autoconfigure"))
optional(project(":spring-boot-project:spring-boot-http"))
optional(project(":spring-boot-project:spring-boot-rsocket"))
optional(project(":spring-boot-project:spring-boot-security"))
optional(project(":spring-boot-project:spring-boot-webflux"))
optional(project(":spring-boot-project:spring-boot-webmvc"))
optional("com.querydsl:querydsl-core")
optional("io.projectreactor.netty:reactor-netty-http")
optional("io.rsocket:rsocket-transport-netty")
optional("jakarta.servlet:jakarta.servlet-api")
optional("jakarta.websocket:jakarta.websocket-api")
optional("jakarta.websocket:jakarta.websocket-client-api")
optional("org.springframework:spring-websocket")
optional("org.springframework.data:spring-data-commons")
testImplementation(project(":spring-boot-project:spring-boot-http-codec"))
testImplementation(project(":spring-boot-project:spring-boot-reactor-netty"))
testImplementation(project(":spring-boot-project:spring-boot-test"))
testImplementation(project(":spring-boot-project:spring-boot-tools:spring-boot-test-support"))
testImplementation("org.springframework.graphql:spring-graphql-test")
testImplementation("org.springframework.security:spring-security-test")
testRuntimeOnly("ch.qos.logback:logback-classic")
}

View File

@ -1,5 +1,5 @@
/* /*
* Copyright 2012-2023 the original author or authors. * Copyright 2012-2025 the original author or authors.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql; package org.springframework.boot.graphql.autoconfigure;
import java.lang.annotation.Documented; import java.lang.annotation.Documented;
import java.lang.annotation.ElementType; import java.lang.annotation.ElementType;
@ -29,7 +29,7 @@ import org.springframework.context.annotation.Conditional;
* the application, through schema files or infrastructure beans. * the application, through schema files or infrastructure beans.
* *
* @author Brian Clozel * @author Brian Clozel
* @since 2.7.0 * @since 4.0.0
*/ */
@Target({ ElementType.TYPE, ElementType.METHOD }) @Target({ ElementType.TYPE, ElementType.METHOD })
@Retention(RetentionPolicy.RUNTIME) @Retention(RetentionPolicy.RUNTIME)

View File

@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql; package org.springframework.boot.graphql.autoconfigure;
import java.io.IOException; import java.io.IOException;
import java.util.ArrayList; import java.util.ArrayList;

View File

@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql; package org.springframework.boot.graphql.autoconfigure;
import java.io.IOException; import java.io.IOException;
import java.util.ArrayList; import java.util.ArrayList;
@ -72,7 +72,7 @@ import org.springframework.graphql.execution.SubscriptionExceptionResolver;
* infrastructure. * infrastructure.
* *
* @author Brian Clozel * @author Brian Clozel
* @since 2.7.0 * @since 4.0.0
*/ */
@AutoConfiguration @AutoConfiguration
@ConditionalOnClass({ GraphQL.class, GraphQlSource.class }) @ConditionalOnClass({ GraphQL.class, GraphQlSource.class })

View File

@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql; package org.springframework.boot.graphql.autoconfigure;
import java.time.Duration; import java.time.Duration;
import java.time.temporal.ChronoUnit; import java.time.temporal.ChronoUnit;
@ -32,7 +32,7 @@ import org.springframework.web.cors.CorsConfiguration;
* *
* @author Andy Wilkinson * @author Andy Wilkinson
* @author Brian Clozel * @author Brian Clozel
* @since 2.7.0 * @since 4.0.0
*/ */
@ConfigurationProperties("spring.graphql.cors") @ConfigurationProperties("spring.graphql.cors")
public class GraphQlCorsProperties { public class GraphQlCorsProperties {

View File

@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql; package org.springframework.boot.graphql.autoconfigure;
import java.time.Duration; import java.time.Duration;
import java.util.Arrays; import java.util.Arrays;
@ -27,7 +27,7 @@ import org.springframework.core.io.Resource;
* {@link ConfigurationProperties Properties} for Spring GraphQL. * {@link ConfigurationProperties Properties} for Spring GraphQL.
* *
* @author Brian Clozel * @author Brian Clozel
* @since 2.7.0 * @since 4.0.0
*/ */
@ConfigurationProperties("spring.graphql") @ConfigurationProperties("spring.graphql")
public class GraphQlProperties { public class GraphQlProperties {

View File

@ -1,5 +1,5 @@
/* /*
* Copyright 2012-2022 the original author or authors. * Copyright 2012-2025 the original author or authors.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql; package org.springframework.boot.graphql.autoconfigure;
import org.springframework.graphql.execution.GraphQlSource; import org.springframework.graphql.execution.GraphQlSource;
@ -24,7 +24,7 @@ import org.springframework.graphql.execution.GraphQlSource;
* Builder} whilst retaining default auto-configuration. * Builder} whilst retaining default auto-configuration.
* *
* @author Rossen Stoyanchev * @author Rossen Stoyanchev
* @since 2.7.0 * @since 4.0.0
*/ */
@FunctionalInterface @FunctionalInterface
public interface GraphQlSourceBuilderCustomizer { public interface GraphQlSourceBuilderCustomizer {

View File

@ -1,5 +1,5 @@
/* /*
* Copyright 2012-2023 the original author or authors. * Copyright 2012-2025 the original author or authors.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql.data; package org.springframework.boot.graphql.autoconfigure.data;
import java.util.Collections; import java.util.Collections;
import java.util.List; import java.util.List;
@ -26,8 +26,8 @@ import org.springframework.boot.autoconfigure.AutoConfiguration;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration; import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean; import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass; import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration; import org.springframework.boot.graphql.autoconfigure.GraphQlAutoConfiguration;
import org.springframework.boot.autoconfigure.graphql.GraphQlSourceBuilderCustomizer; import org.springframework.boot.graphql.autoconfigure.GraphQlSourceBuilderCustomizer;
import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Bean;
import org.springframework.data.repository.query.QueryByExampleExecutor; import org.springframework.data.repository.query.QueryByExampleExecutor;
import org.springframework.graphql.data.query.QueryByExampleDataFetcher; import org.springframework.graphql.data.query.QueryByExampleDataFetcher;
@ -41,7 +41,7 @@ import org.springframework.graphql.execution.RuntimeWiringConfigurer;
* matching return type. * matching return type.
* *
* @author Rossen Stoyanchev * @author Rossen Stoyanchev
* @since 2.7.0 * @since 4.0.0
* @see QueryByExampleDataFetcher#autoRegistrationConfigurer(List, List) * @see QueryByExampleDataFetcher#autoRegistrationConfigurer(List, List)
*/ */
@AutoConfiguration(after = GraphQlAutoConfiguration.class) @AutoConfiguration(after = GraphQlAutoConfiguration.class)

View File

@ -1,5 +1,5 @@
/* /*
* Copyright 2012-2023 the original author or authors. * Copyright 2012-2025 the original author or authors.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql.data; package org.springframework.boot.graphql.autoconfigure.data;
import java.util.Collections; import java.util.Collections;
import java.util.List; import java.util.List;
@ -27,8 +27,8 @@ import org.springframework.boot.autoconfigure.AutoConfiguration;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration; import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean; import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass; import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration; import org.springframework.boot.graphql.autoconfigure.GraphQlAutoConfiguration;
import org.springframework.boot.autoconfigure.graphql.GraphQlSourceBuilderCustomizer; import org.springframework.boot.graphql.autoconfigure.GraphQlSourceBuilderCustomizer;
import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Bean;
import org.springframework.data.querydsl.QuerydslPredicateExecutor; import org.springframework.data.querydsl.QuerydslPredicateExecutor;
import org.springframework.graphql.data.query.QuerydslDataFetcher; import org.springframework.graphql.data.query.QuerydslDataFetcher;
@ -43,7 +43,7 @@ import org.springframework.graphql.execution.RuntimeWiringConfigurer;
* *
* @author Rossen Stoyanchev * @author Rossen Stoyanchev
* @author Brian Clozel * @author Brian Clozel
* @since 2.7.0 * @since 4.0.0
* @see QuerydslDataFetcher#autoRegistrationConfigurer(List, List) * @see QuerydslDataFetcher#autoRegistrationConfigurer(List, List)
*/ */
@AutoConfiguration(after = GraphQlAutoConfiguration.class) @AutoConfiguration(after = GraphQlAutoConfiguration.class)

View File

@ -1,5 +1,5 @@
/* /*
* Copyright 2012-2023 the original author or authors. * Copyright 2012-2025 the original author or authors.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql.data; package org.springframework.boot.graphql.autoconfigure.data;
import java.util.Collections; import java.util.Collections;
import java.util.List; import java.util.List;
@ -26,8 +26,8 @@ import org.springframework.boot.autoconfigure.AutoConfiguration;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration; import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean; import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass; import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration; import org.springframework.boot.graphql.autoconfigure.GraphQlAutoConfiguration;
import org.springframework.boot.autoconfigure.graphql.GraphQlSourceBuilderCustomizer; import org.springframework.boot.graphql.autoconfigure.GraphQlSourceBuilderCustomizer;
import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Bean;
import org.springframework.data.repository.query.ReactiveQueryByExampleExecutor; import org.springframework.data.repository.query.ReactiveQueryByExampleExecutor;
import org.springframework.graphql.data.query.QueryByExampleDataFetcher; import org.springframework.graphql.data.query.QueryByExampleDataFetcher;
@ -41,7 +41,7 @@ import org.springframework.graphql.execution.RuntimeWiringConfigurer;
* matching return type. * matching return type.
* *
* @author Rossen Stoyanchev * @author Rossen Stoyanchev
* @since 2.7.0 * @since 4.0.0
* @see QueryByExampleDataFetcher#autoRegistrationConfigurer(List, List) * @see QueryByExampleDataFetcher#autoRegistrationConfigurer(List, List)
*/ */
@AutoConfiguration(after = GraphQlAutoConfiguration.class) @AutoConfiguration(after = GraphQlAutoConfiguration.class)

View File

@ -1,5 +1,5 @@
/* /*
* Copyright 2012-2023 the original author or authors. * Copyright 2012-2025 the original author or authors.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql.data; package org.springframework.boot.graphql.autoconfigure.data;
import java.util.Collections; import java.util.Collections;
import java.util.List; import java.util.List;
@ -27,8 +27,8 @@ import org.springframework.boot.autoconfigure.AutoConfiguration;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration; import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean; import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass; import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration; import org.springframework.boot.graphql.autoconfigure.GraphQlAutoConfiguration;
import org.springframework.boot.autoconfigure.graphql.GraphQlSourceBuilderCustomizer; import org.springframework.boot.graphql.autoconfigure.GraphQlSourceBuilderCustomizer;
import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Bean;
import org.springframework.data.querydsl.ReactiveQuerydslPredicateExecutor; import org.springframework.data.querydsl.ReactiveQuerydslPredicateExecutor;
import org.springframework.graphql.data.query.QuerydslDataFetcher; import org.springframework.graphql.data.query.QuerydslDataFetcher;
@ -43,7 +43,7 @@ import org.springframework.graphql.execution.RuntimeWiringConfigurer;
* *
* @author Rossen Stoyanchev * @author Rossen Stoyanchev
* @author Brian Clozel * @author Brian Clozel
* @since 2.7.0 * @since 4.0.0
* @see QuerydslDataFetcher#autoRegistrationConfigurer(List, List) * @see QuerydslDataFetcher#autoRegistrationConfigurer(List, List)
*/ */
@AutoConfiguration(after = GraphQlAutoConfiguration.class) @AutoConfiguration(after = GraphQlAutoConfiguration.class)

View File

@ -17,4 +17,4 @@
/** /**
* Auto-configuration classes for data integrations with GraphQL. * Auto-configuration classes for data integrations with GraphQL.
*/ */
package org.springframework.boot.autoconfigure.graphql.data; package org.springframework.boot.graphql.autoconfigure.data;

View File

@ -1,5 +1,5 @@
/* /*
* Copyright 2012-2022 the original author or authors. * Copyright 2012-2025 the original author or authors.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -17,4 +17,4 @@
/** /**
* Auto-configuration for Spring GraphQL. * Auto-configuration for Spring GraphQL.
*/ */
package org.springframework.boot.autoconfigure.graphql; package org.springframework.boot.graphql.autoconfigure;

View File

@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql.reactive; package org.springframework.boot.graphql.autoconfigure.reactive;
import java.util.Collections; import java.util.Collections;
@ -33,10 +33,10 @@ import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean; import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty; import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication; import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication;
import org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration;
import org.springframework.boot.autoconfigure.graphql.GraphQlCorsProperties;
import org.springframework.boot.autoconfigure.graphql.GraphQlProperties;
import org.springframework.boot.context.properties.EnableConfigurationProperties; import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.boot.graphql.autoconfigure.GraphQlAutoConfiguration;
import org.springframework.boot.graphql.autoconfigure.GraphQlCorsProperties;
import org.springframework.boot.graphql.autoconfigure.GraphQlProperties;
import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration; import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.ImportRuntimeHints; import org.springframework.context.annotation.ImportRuntimeHints;
@ -73,7 +73,7 @@ import org.springframework.web.reactive.socket.server.support.WebSocketUpgradeHa
* WebFlux. * WebFlux.
* *
* @author Brian Clozel * @author Brian Clozel
* @since 2.7.0 * @since 4.0.0
*/ */
@AutoConfiguration(after = GraphQlAutoConfiguration.class) @AutoConfiguration(after = GraphQlAutoConfiguration.class)
@ConditionalOnWebApplication(type = ConditionalOnWebApplication.Type.REACTIVE) @ConditionalOnWebApplication(type = ConditionalOnWebApplication.Type.REACTIVE)

View File

@ -17,4 +17,4 @@
/** /**
* Auto-configuration classes for WebFlux support in Spring GraphQL. * Auto-configuration classes for WebFlux support in Spring GraphQL.
*/ */
package org.springframework.boot.autoconfigure.graphql.reactive; package org.springframework.boot.graphql.autoconfigure.reactive;

View File

@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql.rsocket; package org.springframework.boot.graphql.autoconfigure.rsocket;
import com.fasterxml.jackson.databind.ObjectMapper; import com.fasterxml.jackson.databind.ObjectMapper;
import graphql.GraphQL; import graphql.GraphQL;
@ -28,7 +28,7 @@ import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass; import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean; import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty; import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration; import org.springframework.boot.graphql.autoconfigure.GraphQlAutoConfiguration;
import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Bean;
import org.springframework.graphql.ExecutionGraphQlService; import org.springframework.graphql.ExecutionGraphQlService;
import org.springframework.graphql.data.method.annotation.support.AnnotatedControllerConfigurer; import org.springframework.graphql.data.method.annotation.support.AnnotatedControllerConfigurer;
@ -43,7 +43,7 @@ import org.springframework.messaging.rsocket.annotation.support.RSocketMessageHa
* RSocket. * RSocket.
* *
* @author Brian Clozel * @author Brian Clozel
* @since 2.7.0 * @since 4.0.0
*/ */
@AutoConfiguration(after = GraphQlAutoConfiguration.class, @AutoConfiguration(after = GraphQlAutoConfiguration.class,
afterName = "org.springframework.boot.rsocket.autoconfigure.RSocketMessagingAutoConfiguration") afterName = "org.springframework.boot.rsocket.autoconfigure.RSocketMessagingAutoConfiguration")

View File

@ -1,5 +1,5 @@
/* /*
* Copyright 2012-2022 the original author or authors. * Copyright 2012-2025 the original author or authors.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql.rsocket; package org.springframework.boot.graphql.autoconfigure.rsocket;
import java.util.Map; import java.util.Map;

View File

@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql.rsocket; package org.springframework.boot.graphql.autoconfigure.rsocket;
import graphql.GraphQL; import graphql.GraphQL;
import io.rsocket.RSocket; import io.rsocket.RSocket;
@ -39,7 +39,7 @@ import org.springframework.util.MimeTypeUtils;
* not be reused to build client instances with different configurations. * not be reused to build client instances with different configurations.
* *
* @author Brian Clozel * @author Brian Clozel
* @since 2.7.0 * @since 4.0.0
*/ */
@AutoConfiguration(afterName = "org.springframework.boot.rsocket.autoconfigure.RSocketRequesterAutoConfiguration") @AutoConfiguration(afterName = "org.springframework.boot.rsocket.autoconfigure.RSocketRequesterAutoConfiguration")
@ConditionalOnClass({ GraphQL.class, RSocketGraphQlClient.class, RSocketRequester.class, RSocket.class, @ConditionalOnClass({ GraphQL.class, RSocketGraphQlClient.class, RSocketRequester.class, RSocket.class,

View File

@ -17,4 +17,4 @@
/** /**
* Auto-configuration classes for RSocket integration with GraphQL. * Auto-configuration classes for RSocket integration with GraphQL.
*/ */
package org.springframework.boot.autoconfigure.graphql.rsocket; package org.springframework.boot.graphql.autoconfigure.rsocket;

View File

@ -1,5 +1,5 @@
/* /*
* Copyright 2012-2022 the original author or authors. * Copyright 2012-2025 the original author or authors.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql.security; package org.springframework.boot.graphql.autoconfigure.security;
import graphql.GraphQL; import graphql.GraphQL;
@ -24,7 +24,7 @@ import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass; import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean; import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication; import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication;
import org.springframework.boot.autoconfigure.graphql.reactive.GraphQlWebFluxAutoConfiguration; import org.springframework.boot.graphql.autoconfigure.reactive.GraphQlWebFluxAutoConfiguration;
import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Bean;
import org.springframework.graphql.execution.ReactiveSecurityDataFetcherExceptionResolver; import org.springframework.graphql.execution.ReactiveSecurityDataFetcherExceptionResolver;
import org.springframework.graphql.server.webflux.GraphQlHttpHandler; import org.springframework.graphql.server.webflux.GraphQlHttpHandler;
@ -35,7 +35,7 @@ import org.springframework.security.config.annotation.web.reactive.EnableWebFlux
* Spring GraphQL with WebFlux. * Spring GraphQL with WebFlux.
* *
* @author Brian Clozel * @author Brian Clozel
* @since 2.7.0 * @since 4.0.0
*/ */
@AutoConfiguration(after = GraphQlWebFluxAutoConfiguration.class) @AutoConfiguration(after = GraphQlWebFluxAutoConfiguration.class)
@ConditionalOnWebApplication(type = ConditionalOnWebApplication.Type.REACTIVE) @ConditionalOnWebApplication(type = ConditionalOnWebApplication.Type.REACTIVE)

View File

@ -1,5 +1,5 @@
/* /*
* Copyright 2012-2022 the original author or authors. * Copyright 2012-2025 the original author or authors.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql.security; package org.springframework.boot.graphql.autoconfigure.security;
import graphql.GraphQL; import graphql.GraphQL;
@ -24,7 +24,7 @@ import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass; import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean; import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication; import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication;
import org.springframework.boot.autoconfigure.graphql.servlet.GraphQlWebMvcAutoConfiguration; import org.springframework.boot.graphql.autoconfigure.servlet.GraphQlWebMvcAutoConfiguration;
import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Bean;
import org.springframework.graphql.execution.SecurityDataFetcherExceptionResolver; import org.springframework.graphql.execution.SecurityDataFetcherExceptionResolver;
import org.springframework.graphql.server.webmvc.GraphQlHttpHandler; import org.springframework.graphql.server.webmvc.GraphQlHttpHandler;
@ -35,7 +35,7 @@ import org.springframework.security.config.annotation.web.configuration.EnableWe
* Spring GraphQL with MVC. * Spring GraphQL with MVC.
* *
* @author Brian Clozel * @author Brian Clozel
* @since 2.7.0 * @since 4.0.0
*/ */
@AutoConfiguration(after = GraphQlWebMvcAutoConfiguration.class) @AutoConfiguration(after = GraphQlWebMvcAutoConfiguration.class)
@ConditionalOnWebApplication(type = ConditionalOnWebApplication.Type.SERVLET) @ConditionalOnWebApplication(type = ConditionalOnWebApplication.Type.SERVLET)

View File

@ -17,4 +17,4 @@
/** /**
* Auto-configuration classes for Security support in Spring GraphQL. * Auto-configuration classes for Security support in Spring GraphQL.
*/ */
package org.springframework.boot.autoconfigure.graphql.security; package org.springframework.boot.graphql.autoconfigure.security;

View File

@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql.servlet; package org.springframework.boot.graphql.autoconfigure.servlet;
import java.util.Collections; import java.util.Collections;
import java.util.Map; import java.util.Map;
@ -34,10 +34,10 @@ import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean; import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty; import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication; import org.springframework.boot.autoconfigure.condition.ConditionalOnWebApplication;
import org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration;
import org.springframework.boot.autoconfigure.graphql.GraphQlCorsProperties;
import org.springframework.boot.autoconfigure.graphql.GraphQlProperties;
import org.springframework.boot.context.properties.EnableConfigurationProperties; import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.boot.graphql.autoconfigure.GraphQlAutoConfiguration;
import org.springframework.boot.graphql.autoconfigure.GraphQlCorsProperties;
import org.springframework.boot.graphql.autoconfigure.GraphQlProperties;
import org.springframework.boot.http.autoconfigure.HttpMessageConverters; import org.springframework.boot.http.autoconfigure.HttpMessageConverters;
import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration; import org.springframework.context.annotation.Configuration;
@ -77,7 +77,7 @@ import org.springframework.web.socket.server.support.WebSocketHandlerMapping;
* Spring MVC. * Spring MVC.
* *
* @author Brian Clozel * @author Brian Clozel
* @since 2.7.0 * @since 4.0.0
*/ */
@AutoConfiguration(after = GraphQlAutoConfiguration.class) @AutoConfiguration(after = GraphQlAutoConfiguration.class)
@ConditionalOnWebApplication(type = ConditionalOnWebApplication.Type.SERVLET) @ConditionalOnWebApplication(type = ConditionalOnWebApplication.Type.SERVLET)
@ -172,7 +172,7 @@ public class GraphQlWebMvcAutoConfiguration {
} }
@Configuration(proxyBeanMethods = false) @Configuration(proxyBeanMethods = false)
@ConditionalOnClass({ ServerContainer.class, WebSocketHandler.class }) @ConditionalOnClass({ HttpMessageConverters.class, ServerContainer.class, WebSocketHandler.class })
@ConditionalOnProperty("spring.graphql.websocket.path") @ConditionalOnProperty("spring.graphql.websocket.path")
public static class WebSocketConfiguration { public static class WebSocketConfiguration {

View File

@ -17,4 +17,4 @@
/** /**
* Auto-configuration classes for MVC support in Spring GraphQL. * Auto-configuration classes for MVC support in Spring GraphQL.
*/ */
package org.springframework.boot.autoconfigure.graphql.servlet; package org.springframework.boot.graphql.autoconfigure.servlet;

View File

@ -0,0 +1,13 @@
{
"groups": [],
"properties": [
{
"name": "spring.graphql.schema.file-extensions",
"defaultValue": ".graphqls,.gqls"
},
{
"name": "spring.graphql.schema.locations",
"defaultValue": "classpath:graphql/**/"
}
]
}

View File

@ -0,0 +1,11 @@
org.springframework.boot.graphql.autoconfigure.GraphQlAutoConfiguration
org.springframework.boot.graphql.autoconfigure.data.GraphQlReactiveQueryByExampleAutoConfiguration
org.springframework.boot.graphql.autoconfigure.data.GraphQlReactiveQuerydslAutoConfiguration
org.springframework.boot.graphql.autoconfigure.data.GraphQlQueryByExampleAutoConfiguration
org.springframework.boot.graphql.autoconfigure.data.GraphQlQuerydslAutoConfiguration
org.springframework.boot.graphql.autoconfigure.reactive.GraphQlWebFluxAutoConfiguration
org.springframework.boot.graphql.autoconfigure.rsocket.GraphQlRSocketAutoConfiguration
org.springframework.boot.graphql.autoconfigure.rsocket.RSocketGraphQlClientAutoConfiguration
org.springframework.boot.graphql.autoconfigure.security.GraphQlWebFluxSecurityAutoConfiguration
org.springframework.boot.graphql.autoconfigure.security.GraphQlWebMvcSecurityAutoConfiguration
org.springframework.boot.graphql.autoconfigure.servlet.GraphQlWebMvcAutoConfiguration

View File

@ -1,5 +1,5 @@
/* /*
* Copyright 2012-2022 the original author or authors. * Copyright 2012-2025 the original author or authors.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql; package org.springframework.boot.graphql.autoconfigure;
import org.springframework.data.annotation.Id; import org.springframework.data.annotation.Id;

View File

@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql; package org.springframework.boot.graphql.autoconfigure;
import java.util.Collection; import java.util.Collection;

View File

@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql; package org.springframework.boot.graphql.autoconfigure;
import java.nio.charset.StandardCharsets; import java.nio.charset.StandardCharsets;
import java.util.concurrent.Executor; import java.util.concurrent.Executor;
@ -34,8 +34,8 @@ import org.junit.jupiter.api.extension.ExtendWith;
import org.springframework.aot.hint.RuntimeHints; import org.springframework.aot.hint.RuntimeHints;
import org.springframework.aot.hint.predicate.RuntimeHintsPredicates; import org.springframework.aot.hint.predicate.RuntimeHintsPredicates;
import org.springframework.boot.autoconfigure.AutoConfigurations; import org.springframework.boot.autoconfigure.AutoConfigurations;
import org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration.GraphQlResourcesRuntimeHints;
import org.springframework.boot.autoconfigure.task.TaskExecutionAutoConfiguration; import org.springframework.boot.autoconfigure.task.TaskExecutionAutoConfiguration;
import org.springframework.boot.graphql.autoconfigure.GraphQlAutoConfiguration.GraphQlResourcesRuntimeHints;
import org.springframework.boot.test.context.runner.ApplicationContextRunner; import org.springframework.boot.test.context.runner.ApplicationContextRunner;
import org.springframework.boot.test.system.CapturedOutput; import org.springframework.boot.test.system.CapturedOutput;
import org.springframework.boot.test.system.OutputCaptureExtension; import org.springframework.boot.test.system.OutputCaptureExtension;

View File

@ -1,5 +1,5 @@
/* /*
* Copyright 2012-2022 the original author or authors. * Copyright 2012-2025 the original author or authors.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql; package org.springframework.boot.graphql.autoconfigure;
import java.util.Arrays; import java.util.Arrays;
import java.util.List; import java.util.List;

View File

@ -1,5 +1,5 @@
/* /*
* Copyright 2012-2022 the original author or authors. * Copyright 2012-2025 the original author or authors.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql; package org.springframework.boot.graphql.autoconfigure;
import com.querydsl.core.types.Path; import com.querydsl.core.types.Path;
import com.querydsl.core.types.PathMetadata; import com.querydsl.core.types.PathMetadata;

View File

@ -14,13 +14,13 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql.data; package org.springframework.boot.graphql.autoconfigure.data;
import java.util.Optional; import java.util.Optional;
import org.springframework.boot.autoconfigure.AutoConfigurations; import org.springframework.boot.autoconfigure.AutoConfigurations;
import org.springframework.boot.autoconfigure.graphql.Book; import org.springframework.boot.graphql.autoconfigure.Book;
import org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration; import org.springframework.boot.graphql.autoconfigure.GraphQlAutoConfiguration;
import org.springframework.boot.test.context.runner.WebApplicationContextRunner; import org.springframework.boot.test.context.runner.WebApplicationContextRunner;
import org.springframework.boot.testsupport.classpath.resources.WithResource; import org.springframework.boot.testsupport.classpath.resources.WithResource;
import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Bean;

View File

@ -14,15 +14,15 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql.data; package org.springframework.boot.graphql.autoconfigure.data;
import java.util.Optional; import java.util.Optional;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
import org.springframework.boot.autoconfigure.AutoConfigurations; import org.springframework.boot.autoconfigure.AutoConfigurations;
import org.springframework.boot.autoconfigure.graphql.Book; import org.springframework.boot.graphql.autoconfigure.Book;
import org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration; import org.springframework.boot.graphql.autoconfigure.GraphQlAutoConfiguration;
import org.springframework.boot.test.context.FilteredClassLoader; import org.springframework.boot.test.context.FilteredClassLoader;
import org.springframework.boot.test.context.runner.WebApplicationContextRunner; import org.springframework.boot.test.context.runner.WebApplicationContextRunner;
import org.springframework.boot.testsupport.classpath.resources.WithResource; import org.springframework.boot.testsupport.classpath.resources.WithResource;

View File

@ -14,14 +14,14 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql.data; package org.springframework.boot.graphql.autoconfigure.data;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
import reactor.core.publisher.Mono; import reactor.core.publisher.Mono;
import org.springframework.boot.autoconfigure.AutoConfigurations; import org.springframework.boot.autoconfigure.AutoConfigurations;
import org.springframework.boot.autoconfigure.graphql.Book; import org.springframework.boot.graphql.autoconfigure.Book;
import org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration; import org.springframework.boot.graphql.autoconfigure.GraphQlAutoConfiguration;
import org.springframework.boot.test.context.runner.ReactiveWebApplicationContextRunner; import org.springframework.boot.test.context.runner.ReactiveWebApplicationContextRunner;
import org.springframework.boot.testsupport.classpath.resources.WithResource; import org.springframework.boot.testsupport.classpath.resources.WithResource;
import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Bean;

View File

@ -14,14 +14,14 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql.data; package org.springframework.boot.graphql.autoconfigure.data;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
import reactor.core.publisher.Mono; import reactor.core.publisher.Mono;
import org.springframework.boot.autoconfigure.AutoConfigurations; import org.springframework.boot.autoconfigure.AutoConfigurations;
import org.springframework.boot.autoconfigure.graphql.Book; import org.springframework.boot.graphql.autoconfigure.Book;
import org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration; import org.springframework.boot.graphql.autoconfigure.GraphQlAutoConfiguration;
import org.springframework.boot.test.context.FilteredClassLoader; import org.springframework.boot.test.context.FilteredClassLoader;
import org.springframework.boot.test.context.runner.ReactiveWebApplicationContextRunner; import org.springframework.boot.test.context.runner.ReactiveWebApplicationContextRunner;
import org.springframework.boot.testsupport.classpath.resources.WithResource; import org.springframework.boot.testsupport.classpath.resources.WithResource;

View File

@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql.reactive; package org.springframework.boot.graphql.autoconfigure.reactive;
import java.time.Duration; import java.time.Duration;
import java.util.Collections; import java.util.Collections;
@ -27,8 +27,8 @@ import org.junit.jupiter.api.Test;
import org.springframework.aot.hint.RuntimeHints; import org.springframework.aot.hint.RuntimeHints;
import org.springframework.aot.hint.predicate.RuntimeHintsPredicates; import org.springframework.aot.hint.predicate.RuntimeHintsPredicates;
import org.springframework.boot.autoconfigure.AutoConfigurations; import org.springframework.boot.autoconfigure.AutoConfigurations;
import org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration; import org.springframework.boot.graphql.autoconfigure.GraphQlAutoConfiguration;
import org.springframework.boot.autoconfigure.graphql.GraphQlTestDataFetchers; import org.springframework.boot.graphql.autoconfigure.GraphQlTestDataFetchers;
import org.springframework.boot.http.codec.autoconfigure.CodecsAutoConfiguration; import org.springframework.boot.http.codec.autoconfigure.CodecsAutoConfiguration;
import org.springframework.boot.jackson.autoconfigure.JacksonAutoConfiguration; import org.springframework.boot.jackson.autoconfigure.JacksonAutoConfiguration;
import org.springframework.boot.test.context.runner.ReactiveWebApplicationContextRunner; import org.springframework.boot.test.context.runner.ReactiveWebApplicationContextRunner;

View File

@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql.rsocket; package org.springframework.boot.graphql.autoconfigure.rsocket;
import java.net.URI; import java.net.URI;
import java.time.Duration; import java.time.Duration;
@ -25,8 +25,8 @@ import org.junit.jupiter.api.Test;
import org.springframework.boot.autoconfigure.AutoConfigurations; import org.springframework.boot.autoconfigure.AutoConfigurations;
import org.springframework.boot.autoconfigure.context.PropertyPlaceholderAutoConfiguration; import org.springframework.boot.autoconfigure.context.PropertyPlaceholderAutoConfiguration;
import org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration; import org.springframework.boot.graphql.autoconfigure.GraphQlAutoConfiguration;
import org.springframework.boot.autoconfigure.graphql.GraphQlTestDataFetchers; import org.springframework.boot.graphql.autoconfigure.GraphQlTestDataFetchers;
import org.springframework.boot.jackson.autoconfigure.JacksonAutoConfiguration; import org.springframework.boot.jackson.autoconfigure.JacksonAutoConfiguration;
import org.springframework.boot.reactor.netty.NettyReactiveWebServerFactory; import org.springframework.boot.reactor.netty.NettyReactiveWebServerFactory;
import org.springframework.boot.reactor.netty.NettyRouteProvider; import org.springframework.boot.reactor.netty.NettyRouteProvider;

View File

@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql.rsocket; package org.springframework.boot.graphql.autoconfigure.rsocket;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;

View File

@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql.security; package org.springframework.boot.graphql.autoconfigure.security;
import java.util.Collections; import java.util.Collections;
import java.util.function.Consumer; import java.util.function.Consumer;
@ -24,10 +24,10 @@ import org.junit.jupiter.api.Test;
import reactor.core.publisher.Mono; import reactor.core.publisher.Mono;
import org.springframework.boot.autoconfigure.AutoConfigurations; import org.springframework.boot.autoconfigure.AutoConfigurations;
import org.springframework.boot.autoconfigure.graphql.Book; import org.springframework.boot.graphql.autoconfigure.Book;
import org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration; import org.springframework.boot.graphql.autoconfigure.GraphQlAutoConfiguration;
import org.springframework.boot.autoconfigure.graphql.GraphQlTestDataFetchers; import org.springframework.boot.graphql.autoconfigure.GraphQlTestDataFetchers;
import org.springframework.boot.autoconfigure.graphql.reactive.GraphQlWebFluxAutoConfiguration; import org.springframework.boot.graphql.autoconfigure.reactive.GraphQlWebFluxAutoConfiguration;
import org.springframework.boot.http.codec.autoconfigure.CodecsAutoConfiguration; import org.springframework.boot.http.codec.autoconfigure.CodecsAutoConfiguration;
import org.springframework.boot.jackson.autoconfigure.JacksonAutoConfiguration; import org.springframework.boot.jackson.autoconfigure.JacksonAutoConfiguration;
import org.springframework.boot.security.autoconfigure.reactive.ReactiveSecurityAutoConfiguration; import org.springframework.boot.security.autoconfigure.reactive.ReactiveSecurityAutoConfiguration;

View File

@ -14,17 +14,17 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql.security; package org.springframework.boot.graphql.autoconfigure.security;
import graphql.schema.idl.TypeRuntimeWiring; import graphql.schema.idl.TypeRuntimeWiring;
import org.assertj.core.api.ThrowingConsumer; import org.assertj.core.api.ThrowingConsumer;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
import org.springframework.boot.autoconfigure.AutoConfigurations; import org.springframework.boot.autoconfigure.AutoConfigurations;
import org.springframework.boot.autoconfigure.graphql.Book; import org.springframework.boot.graphql.autoconfigure.Book;
import org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration; import org.springframework.boot.graphql.autoconfigure.GraphQlAutoConfiguration;
import org.springframework.boot.autoconfigure.graphql.GraphQlTestDataFetchers; import org.springframework.boot.graphql.autoconfigure.GraphQlTestDataFetchers;
import org.springframework.boot.autoconfigure.graphql.servlet.GraphQlWebMvcAutoConfiguration; import org.springframework.boot.graphql.autoconfigure.servlet.GraphQlWebMvcAutoConfiguration;
import org.springframework.boot.http.autoconfigure.HttpMessageConvertersAutoConfiguration; import org.springframework.boot.http.autoconfigure.HttpMessageConvertersAutoConfiguration;
import org.springframework.boot.jackson.autoconfigure.JacksonAutoConfiguration; import org.springframework.boot.jackson.autoconfigure.JacksonAutoConfiguration;
import org.springframework.boot.security.autoconfigure.servlet.SecurityAutoConfiguration; import org.springframework.boot.security.autoconfigure.servlet.SecurityAutoConfiguration;

View File

@ -14,7 +14,7 @@
* limitations under the License. * limitations under the License.
*/ */
package org.springframework.boot.autoconfigure.graphql.servlet; package org.springframework.boot.graphql.autoconfigure.servlet;
import java.time.Duration; import java.time.Duration;
import java.util.List; import java.util.List;
@ -27,8 +27,8 @@ import org.junit.jupiter.api.Test;
import org.springframework.aot.hint.RuntimeHints; import org.springframework.aot.hint.RuntimeHints;
import org.springframework.aot.hint.predicate.RuntimeHintsPredicates; import org.springframework.aot.hint.predicate.RuntimeHintsPredicates;
import org.springframework.boot.autoconfigure.AutoConfigurations; import org.springframework.boot.autoconfigure.AutoConfigurations;
import org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration; import org.springframework.boot.graphql.autoconfigure.GraphQlAutoConfiguration;
import org.springframework.boot.autoconfigure.graphql.GraphQlTestDataFetchers; import org.springframework.boot.graphql.autoconfigure.GraphQlTestDataFetchers;
import org.springframework.boot.http.autoconfigure.HttpMessageConvertersAutoConfiguration; import org.springframework.boot.http.autoconfigure.HttpMessageConvertersAutoConfiguration;
import org.springframework.boot.jackson.autoconfigure.JacksonAutoConfiguration; import org.springframework.boot.jackson.autoconfigure.JacksonAutoConfiguration;
import org.springframework.boot.test.context.runner.WebApplicationContextRunner; import org.springframework.boot.test.context.runner.WebApplicationContextRunner;

View File

@ -5,7 +5,7 @@ plugins {
description = "Starter for building GraphQL applications with Spring GraphQL" description = "Starter for building GraphQL applications with Spring GraphQL"
dependencies { dependencies {
api(project(":spring-boot-project:spring-boot-graphql"))
api(project(":spring-boot-project:spring-boot-starters:spring-boot-starter")) api(project(":spring-boot-project:spring-boot-starters:spring-boot-starter"))
api(project(":spring-boot-project:spring-boot-starters:spring-boot-starter-json")) api(project(":spring-boot-project:spring-boot-starters:spring-boot-starter-json"))
api("org.springframework.graphql:spring-graphql")
} }

View File

@ -49,6 +49,7 @@ dependencies {
optional(project(":spring-boot-project:spring-boot-data-redis")) optional(project(":spring-boot-project:spring-boot-data-redis"))
optional(project(":spring-boot-project:spring-boot-data-web")) optional(project(":spring-boot-project:spring-boot-data-web"))
optional(project(":spring-boot-project:spring-boot-flyway")) optional(project(":spring-boot-project:spring-boot-flyway"))
optional(project(":spring-boot-project:spring-boot-graphql"))
optional(project(":spring-boot-project:spring-boot-groovy-templates")) optional(project(":spring-boot-project:spring-boot-groovy-templates"))
optional(project(":spring-boot-project:spring-boot-hateoas")) optional(project(":spring-boot-project:spring-boot-hateoas"))
optional(project(":spring-boot-project:spring-boot-http")) optional(project(":spring-boot-project:spring-boot-http"))

View File

@ -35,7 +35,7 @@ import org.springframework.boot.autoconfigure.ImportAutoConfiguration;
* @see GraphQlTest * @see GraphQlTest
* @see org.springframework.boot.http.codec.autoconfigure.CodecsAutoConfiguration * @see org.springframework.boot.http.codec.autoconfigure.CodecsAutoConfiguration
* @see org.springframework.boot.validation.autoconfigure.ValidationAutoConfiguration * @see org.springframework.boot.validation.autoconfigure.ValidationAutoConfiguration
* @see org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration * @see org.springframework.boot.graphql.autoconfigure.GraphQlAutoConfiguration
*/ */
@Target(ElementType.TYPE) @Target(ElementType.TYPE)
@Retention(RetentionPolicy.RUNTIME) @Retention(RetentionPolicy.RUNTIME)

View File

@ -23,8 +23,8 @@ import java.util.Set;
import graphql.execution.instrumentation.Instrumentation; import graphql.execution.instrumentation.Instrumentation;
import org.springframework.boot.autoconfigure.graphql.GraphQlSourceBuilderCustomizer;
import org.springframework.boot.context.TypeExcludeFilter; import org.springframework.boot.context.TypeExcludeFilter;
import org.springframework.boot.graphql.autoconfigure.GraphQlSourceBuilderCustomizer;
import org.springframework.boot.jackson.JsonComponent; import org.springframework.boot.jackson.JsonComponent;
import org.springframework.boot.test.autoconfigure.filter.StandardAnnotationCustomizableTypeExcludeFilter; import org.springframework.boot.test.autoconfigure.filter.StandardAnnotationCustomizableTypeExcludeFilter;
import org.springframework.core.convert.converter.Converter; import org.springframework.core.convert.converter.Converter;

View File

@ -24,7 +24,7 @@ import org.springframework.boot.autoconfigure.AutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean; import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass; import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean; import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration; import org.springframework.boot.graphql.autoconfigure.GraphQlAutoConfiguration;
import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Bean;
import org.springframework.graphql.ExecutionGraphQlService; import org.springframework.graphql.ExecutionGraphQlService;
import org.springframework.graphql.test.tester.ExecutionGraphQlServiceTester; import org.springframework.graphql.test.tester.ExecutionGraphQlServiceTester;

View File

@ -20,7 +20,7 @@ import org.springframework.boot.autoconfigure.AutoConfiguration;
import org.springframework.boot.autoconfigure.condition.ConditionalOnBean; import org.springframework.boot.autoconfigure.condition.ConditionalOnBean;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass; import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean; import org.springframework.boot.autoconfigure.condition.ConditionalOnMissingBean;
import org.springframework.boot.autoconfigure.graphql.GraphQlProperties; import org.springframework.boot.graphql.autoconfigure.GraphQlProperties;
import org.springframework.boot.test.autoconfigure.web.reactive.WebTestClientAutoConfiguration; import org.springframework.boot.test.autoconfigure.web.reactive.WebTestClientAutoConfiguration;
import org.springframework.boot.test.autoconfigure.web.servlet.MockMvcAutoConfiguration; import org.springframework.boot.test.autoconfigure.web.servlet.MockMvcAutoConfiguration;
import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Bean;

View File

@ -1,4 +1,4 @@
# AutoConfigureGraphQl auto-configuration imports # AutoConfigureGraphQl auto-configuration imports
optional:org.springframework.boot.http.codec.autoconfigure.CodecsAutoConfiguration optional:org.springframework.boot.http.codec.autoconfigure.CodecsAutoConfiguration
optional:org.springframework.boot.validation.autoconfigure.ValidationAutoConfiguration optional:org.springframework.boot.validation.autoconfigure.ValidationAutoConfiguration
org.springframework.boot.autoconfigure.graphql.GraphQlAutoConfiguration org.springframework.boot.graphql.autoconfigure.GraphQlAutoConfiguration

View File

@ -1,5 +1,5 @@
/* /*
* Copyright 2012-2022 the original author or authors. * Copyright 2012-2025 the original author or authors.
* *
* Licensed under the Apache License, Version 2.0 (the "License"); * Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. * you may not use this file except in compliance with the License.
@ -27,7 +27,7 @@ import graphql.schema.idl.RuntimeWiring;
import org.junit.jupiter.api.Test; import org.junit.jupiter.api.Test;
import reactor.core.publisher.Mono; import reactor.core.publisher.Mono;
import org.springframework.boot.autoconfigure.graphql.GraphQlSourceBuilderCustomizer; import org.springframework.boot.graphql.autoconfigure.GraphQlSourceBuilderCustomizer;
import org.springframework.context.annotation.ComponentScan; import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.FilterType; import org.springframework.context.annotation.FilterType;
import org.springframework.core.type.classreading.MetadataReader; import org.springframework.core.type.classreading.MetadataReader;

View File

@ -2,3 +2,5 @@
spring.thymeleaf.cache: false spring.thymeleaf.cache: false
server.tomcat.access_log_enabled: true server.tomcat.access_log_enabled: true
server.tomcat.basedir: target/tomcat server.tomcat.basedir: target/tomcat
logging.level.org.thymeleaf:trace