212 Commits

Author SHA1 Message Date
Brian Clozel
7e602f093e Merge branch '1.3.x' 2025-05-16 18:16:02 +02:00
Brian Clozel
e17903051c Inject prepared GraphqlErrorBuilder in error handling methods
Prior to this commit, error handling methods would support various
arguments, including the exception being handled.
Our reference documentation would advise to create a new instance of a
`GraphQLError` using `GraphQLError.newError()`. This does not initialize
the location and path information of the current error.

This commit allows error handling methods to get injected with a
`GraphQlErrorBuilder<?>` argument that is initialized with the current
`DataFetchingEnvironment` (thus filling the location and path parts).

Fixes gh-1200
2025-05-16 18:09:42 +02:00
Brian Clozel
ac9616fd9f Revert ArgumentValue->FieldValue changes
See gh-1187
See gh-1190
See gh-1174
2025-04-15 12:02:29 +02:00
Brian Clozel
70f16c1158 Configure JSON GraphQlModule in client support
The various GraphQL clients supported in this project automatically detect
JSON codecs for reading/writing GraphQL requests as JSON payloads.
If there is none detected, clients provide a default codec instance.

This commit configures automatically the `GraphQlModule` from gh-1174 in
default codecs and add integration tests for `FieldValue<T>` usage on the
client side.

This also improves the documentation around `FieldValue<T>` for both
server and client side support.

Closes gh-1190
2025-04-15 11:44:05 +02:00
Brian Clozel
4ce9ca71c2 Polishing 2025-04-01 17:27:04 +02:00
Brian Clozel
3c97533725 Document use of local context in Controllers
See gh-1167
2025-04-01 17:24:18 +02:00
Brian Clozel
a5ec819748 Merge branch '1.3.x' 2025-03-14 09:40:35 +01:00
Brian Clozel
6d471cd7b8 Add TimeoutWebGraphQlInterceptor
This commit adds a new web interceptor that can be configured with a
specific duration. If the response is not produced within this timeline,
the interceptor sends a HTTP error status to the client (by default,
"REQUEST TIMEOUT" but this can be configured) and sends a CANCEL signal
upstream.
This CANCEL signal flows up to controller methods and maually registered
data fetchers, if they have a reactive return type. Processing will be
automatically aborted.
For other types of date fetchers, applications can retrieve a publisher
from the GraphQL context and get notified of cancellations.

Closes gh-450
2025-03-12 17:00:18 +01:00
Brian Clozel
1979e435c3 Upgrade to GraphQL Java 22.2
This also documents the new subscription ordering feature as reported
and requested in #949.

Closes gh-1044
2024-08-21 18:12:48 +02:00
Brian Clozel
311531b74f Move client and testing docs to compiled code snippets
Prior to this commit, the "client" and "testing" sections of the
reference documentation were using inline code snippets.
Because of this, several snippets were out of date or invalid.

This commit moves all those code snippets to actual Java classes
compiled with the documentation.

Fixes gh-1042
2024-08-21 10:44:54 +02:00
Brian Clozel
c1ed773cc7 Document minimum standalone setup for GraphQL support
Most Spring for GraphQL applications use Spring Boot as a way to
auto-configure the required infrastructure for running GraphQL
applications.

This commit documents a minimal setup for Spring applications not
relying on Spring Boot. This assumes an existing infrastructure for a
Spring MVC application.

Closes gh-606
2024-07-12 16:06:48 +02:00
Brian Clozel
2cb43e9368 Polishing
See gh-863
2024-04-16 17:26:00 +02:00
Brian Clozel
1d98f9b45f Document schema Namespacing with annotated controllers
Closes gh-863
2024-04-16 17:16:44 +02:00
Brian Clozel
4f1f0a2b20 Apply checkstyle changes to spring-graphql-docs
See gh-943
2024-04-04 22:05:38 +02:00
Rob Winch
49446b7171 Migrate Structure 2023-08-04 15:38:28 +01:00
rstoyanchev
142ca8cd73 Add section on file uploads
Closes gh-747
2023-07-18 15:07:25 +01:00
rstoyanchev
db525f18f4 Fix incorrect nesting under Transports section 2023-07-18 12:42:18 +01:00
reillylm
0a2caacf9d fix typo in Reference Docs (Request Execution)
Looks like AsciiDoc syntax needs double backticks for plural words like this
2023-07-17 09:03:28 +01:00
rstoyanchev
7ae8c441f9 Update docs on client side cancellation of subscription
Closes gh-724
2023-07-03 11:11:58 +01:00
Gerrit Meier
f4c5003376 Add tests for Neo4j
Also mention Neo4j as compatible with the reactive stack
and the QuerydslPredicateExecutor.

See gh-734
2023-07-03 06:05:48 +01:00
Brian Clozel
054aaedb16 Document GraphiQL integration
Closes gh-403
2023-05-15 10:49:21 +02:00
Brian Clozel
97990c2543 Rewrite links to new Framework reference docs 2023-05-15 10:49:21 +02:00
Brian Clozel
992b3f4344 Extract large sections of ref docs into includes 2023-05-15 10:49:21 +02:00
rstoyanchev
577014f4f1 Support date types in JsonKeysetCursorStrategy
This adds support for date values to JsonKeysetCursorStrategy by default
when Jackson is on the classpath and also updates the documentation to
provide guidance.

Closes gh-684
2023-05-09 07:02:42 +01:00
rstoyanchev
21f4520a37 Support nested paths in GraphQlTester
Closes gh-457
2023-05-07 21:19:03 +01:00
rstoyanchev
2e7b0108d9 Show pagination args in reference docs sample 2023-05-07 19:37:47 +01:00
rstoyanchev
d3ea23e878 Add hook for the inspection of schema mappings
Closes gh-672
2023-04-28 12:52:29 +01:00
Brian Clozel
75fefe6a58 Merge branch '1.1.x' 2023-04-24 22:57:04 +02:00
Brian Clozel
4e5aaeddab Revisit request observation context type
Prior to this commit, the request execution observation would have a
context of type `RequestReplyReceiverContext` to directly deal with
tracing propagation at the transport level. This approach doesn't work
anymore as the parent observation is not properly set on the resulting
trace, even if it is manually set in the instrumentation.

This commit revisits the request observation setup and turns its context
into a regular `Observation.Context`. Tracing propagation should be
dealt with directly at the transport level by an underlying observation.
This is the case already for Spring Framework HTTP server observations.

As a result, the `PropagationWebGraphQlInterceptor` is deprecated with
no replacement and should not be used anymore.

Fixes gh-675
2023-04-24 22:03:34 +02:00
rstoyanchev
6d8f789d38 SchemaMappingInspector detects unmapped DataFetcher's
Closes gh-671
2023-04-21 09:46:01 +01:00
rstoyanchev
fb6a225193 Polishing in SchemaMappingInspector 2023-04-20 15:46:05 +01:00
rstoyanchev
d933828a23 Polishing
See gh-662
2023-04-19 16:23:39 +01:00
rstoyanchev
63fca20b5b Further update docs for schema mapping inspection
See gh-662
2023-04-19 16:06:03 +01:00
rstoyanchev
ca526f5769 Document schema mapping inspection
Closes gh-662
2023-04-19 14:19:33 +01:00
rstoyanchev
8ec513b799 Minor refactoring in reference docs
Update order of sections under GraphQlSource to reflect actual order of
initialization in addition to minor polishing.
2023-04-19 14:19:33 +01:00
rstoyanchev
145ab22bf3 Merge branch '1.1.x' 2023-04-14 08:29:53 +01:00
rstoyanchev
c650db895b Add link in documentation to Apollo federation sample
Closes gh-384
2023-04-14 08:27:17 +01:00
rstoyanchev
882ad0eb26 Allow fallback on field access for argument binding
Closes gh-599
2023-04-13 18:37:55 +01:00
rstoyanchev
a0d7cc1c8c Expose CursorsStrategy and Subrange as builder options
This makes it possible to customize these settings individually,
optionally, and via QuerydslBuilderCustomizer.

See gh-597
2023-04-12 11:18:40 +01:00
rstoyanchev
1f0c5239c0 Reference docs for Querydsl and QBE pagination
Closes gh-597
2023-04-12 10:26:42 +01:00
rstoyanchev
911b78237c Querydsl and QBE nest into single argument input type
Closes gh-216
2023-03-23 18:29:57 +00:00
rstoyanchev
1a24e31f0f Polishing documentation
See gh-620
2023-03-21 16:09:42 +00:00
rstoyanchev
ee493ef911 Polishing documentation
See gh-620
2023-03-21 13:58:09 +00:00
rstoyanchev
4f873a31eb Add documentation for pagination
Closes gh-620
2023-03-21 12:13:49 +00:00
rstoyanchev
3b1c9c0957 Update reference docs for annotated exception handlers
Closes gh-160
2023-03-06 12:52:00 +00:00
rstoyanchev
7ce33fb6ab Merge branch '1.1.x' 2023-02-20 18:22:54 +00:00
rstoyanchev
dc90558d9a Configure ExecutionInput in ExecutionGraphQlServiceTester
Closes gh-615
2023-02-16 18:20:45 +00:00
rstoyanchev
1ae33a8ba5 Remove ArgumentMapMethodArgumentResolver
Dropping this the dedicated resolver for @Argument Map<String, Object>
leaves it to ArgumentMethodArgumentResolver and
ArgumentsMethodArgumentResolver to handle the case of
Map<String, Object>, treating it either as a raw argument value for a
named argument, or as the full raw arguments map.

Closes gh-548
2023-02-01 14:49:01 +00:00
rstoyanchev
562d39a9a2 Revert "Remove ArgumentMapMethodArgumentResolver"
This reverts commit 7b30159109.
2023-02-01 09:46:14 +00:00
rstoyanchev
483ef31b5f Add link to Getting Started Guides
Closes gh-551
2023-02-01 09:44:29 +00:00