File tree Expand file tree Collapse file tree 3 files changed +42
-0
lines changed
framework-docs/modules/ROOT Expand file tree Collapse file tree 3 files changed +42
-0
lines changed Original file line number Diff line number Diff line change 197
197
*** xref:web/webmvc-functional.adoc[]
198
198
*** xref:web/webmvc/mvc-uri-building.adoc[]
199
199
*** xref:web/webmvc/mvc-ann-async.adoc[]
200
+ *** xref:web/webmvc/mvc-range.adoc[]
200
201
*** xref:web/webmvc-cors.adoc[]
201
202
*** xref:web/webmvc-versioning.adoc[]
202
203
*** xref:web/webmvc/mvc-ann-rest-exceptions.adoc[]
294
295
**** xref:web/webflux/controller/ann-advice.adoc[]
295
296
*** xref:web/webflux-functional.adoc[]
296
297
*** xref:web/webflux/uri-building.adoc[]
298
+ *** xref:web/webflux/range.adoc[]
297
299
*** xref:web/webflux-cors.adoc[]
298
300
*** xref:web/webflux-versioning.adoc[]
299
301
*** xref:web/webflux/ann-rest-exceptions.adoc[]
Original file line number Diff line number Diff line change
1
+ [[webflux-range]]
2
+ = Range Requests
3
+ :page-section-summary-toc: 1
4
+
5
+ [.small]#xref:web/webmvc/mvc-range.adoc[See equivalent in the Servlet stack]#
6
+
7
+ Spring WebFlux supports https://datatracker.ietf.org/doc/html/rfc9110#section-14[RFC 9110]
8
+ range requests. For an overview, see the
9
+ https://developer.mozilla.org/en-US/docs/Web/HTTP/Guides/Range_requests[Ranger Requests]
10
+ Mozilla guide.
11
+
12
+ The `Range` header is parsed and handled transparently in WebFlux when an annotated
13
+ controller returns a `Resource` or `ResponseEntity<Resource>`, or a functional endpoint
14
+ xref:web/webflux-functional.adoc#webflux-fn-resources[serves a `Resource`]. `Range` header
15
+ support is also transparently handled when serving
16
+ xref:web/webflux/config.adoc#webflux-config-static-resources[static resources].
17
+
18
+ The underlying support is in the `HttpRange` class, which exposes methods to parse
19
+ `Range` headers and split a `Resource` into a `List<ResourceRegion>` that in turn can be
20
+ then written to the response via `ResourceRegionEncoder` and `ResourceHttpMessageWriter`.
Original file line number Diff line number Diff line change
1
+ [[mvc-range]]
2
+ = Range Requests
3
+ :page-section-summary-toc: 1
4
+
5
+ [.small]#xref:web/webflux/range.adoc[See equivalent in the Reactive stack]#
6
+
7
+ Spring MVC supports https://datatracker.ietf.org/doc/html/rfc9110#section-14[RFC 9110]
8
+ range requests. For an overview, see the
9
+ https://developer.mozilla.org/en-US/docs/Web/HTTP/Guides/Range_requests[Ranger Requests]
10
+ Mozilla guide.
11
+
12
+ The `Range` header is parsed and handled transparently in Spring MVC when an annotated
13
+ controller returns a `Resource` or `ResponseEntity<Resource>`, or a functional endpoint
14
+ xref:web/webmvc-functional.adoc#webmvc-fn-resources[serves a `Resource`]. `Range` header
15
+ support is also transparently handled when serving
16
+ xref:web/webmvc/mvc-config/static-resources.adoc[static resources].
17
+
18
+ The underlying support is in the `HttpRange` class, which exposes methods to parse
19
+ `Range` headers and split a `Resource` into a `List<ResourceRegion>` that in turn can be
20
+ then written to the response via `ResourceRegionHttpMessageConverter`.
You can’t perform that action at this time.
0 commit comments