Skip to content

Commit 8f9323d

Browse files
committed
Document "classpath:*" location for GraphQL Schemas
This commit mentions the `"classpath*:graphql/**` schema location in case the application needs to find schemas across multiple classpath roots, for example across multiple modules. Closes gh-31772
1 parent c5a4b1f commit 8f9323d

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

spring-boot-project/spring-boot-docs/src/docs/asciidoc/web/spring-graphql.adoc

+3
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,9 @@ A Spring GraphQL application requires a defined schema at startup.
3535
By default, you can write ".graphqls" or ".gqls" schema files under `src/main/resources/graphql/**` and Spring Boot will pick them up automatically.
3636
You can customize the locations with configprop:spring.graphql.schema.locations[] and the file extensions with configprop:spring.graphql.schema.file-extensions[].
3737

38+
NOTE: If you want Spring Boot to detect schema files in all your application modules and dependencies for that location,
39+
you can set configprop:spring.graphql.schema.locations[] to `+"classpath*:graphql/**/"+` (note the `classpath*:` prefix).
40+
3841
In the following sections, we'll consider this sample GraphQL schema, defining two types and two queries:
3942

4043
[source,json,indent=0,subs="verbatim,quotes"]

0 commit comments

Comments
 (0)