Browse Source

Update docs on supported versions with baseline notation

Closes gh-36316
pull/36359/head
rstoyanchev 4 weeks ago
parent
commit
85c18caf25
  1. 10
      framework-docs/modules/ROOT/pages/web/webflux/controller/ann-requestmapping.adoc
  2. 11
      framework-docs/modules/ROOT/pages/web/webmvc/mvc-controller/ann-requestmapping.adoc

10
framework-docs/modules/ROOT/pages/web/webflux/controller/ann-requestmapping.adoc

@ -394,7 +394,8 @@ Once API versioning is enabled, you can begin to map requests with versions. @@ -394,7 +394,8 @@ Once API versioning is enabled, you can begin to map requests with versions.
The `@RequestMapping` `version` attribute supports the following:
- Fixed version ("1.2") -- matches the given version only
- Baseline version ("1.2+") -- matches the given version and above
- Baseline version ("1.2+") -- matches the given and
xref:web/webflux/config.adoc#webflux-config-api-version[supported versions] above
- No value -- matches any version, but is superseded by a more specific version match
If multiple controller methods have a version less than or equal to the request version,
@ -443,6 +444,9 @@ For request with version `"1.3"`: @@ -443,6 +444,9 @@ For request with version `"1.3"`:
- (3) matches as it matches 1.2 and above, and is *chosen* as the highest match
- (4) is higher and does not match
NOTE: Version 1.3 must be present in the mappings, or be
xref:web/webflux/config.adoc#webflux-config-api-version[configured as supported].
For request with version `"1.5"`:
- (1) matches as it matches any version
@ -459,10 +463,6 @@ versioned alternative was introduced. Therefore, even though an unversioned cont @@ -459,10 +463,6 @@ versioned alternative was introduced. Therefore, even though an unversioned cont
method is considered a match for any version, it is in fact given the lowest priority,
and is effectively superseded by any alternative controller method with a version.
NOTE: The above assumes the request version is a
xref:web/webflux/config.adoc#webflux-config-api-version["supported" version],
or otherwise it would fail.
See xref:web/webflux-versioning.adoc[API Versioning] for more details on underlying
infrastructure and support for API Versioning.

11
framework-docs/modules/ROOT/pages/web/webmvc/mvc-controller/ann-requestmapping.adoc

@ -425,7 +425,7 @@ Once API versioning is enabled, you can begin to map requests with versions. @@ -425,7 +425,7 @@ Once API versioning is enabled, you can begin to map requests with versions.
The `@RequestMapping` `version` attribute supports the following:
- Fixed version ("1.2") -- matches the given version only
- Baseline version ("1.2+") -- matches the given version and above
- Baseline version ("1.2+") -- matches the given and xref:web/webmvc/mvc-config/api-version.adoc[supported versions] above
- No value -- matches any version, but is superseded by a more specific version match
If multiple controller methods have a version less than or equal to the request version,
@ -463,7 +463,7 @@ Java:: @@ -463,7 +463,7 @@ Java::
----
<1> match any version
<2> match version 1.1
<3> match version 1.2 and above
<3> match version 1.2 and supported versions above
<4> match version 1.5
======
@ -474,6 +474,9 @@ For request with version `"1.3"`: @@ -474,6 +474,9 @@ For request with version `"1.3"`:
- (3) matches as it matches 1.2 and above, and is *chosen* as the highest match
- (4) is higher and does not match
NOTE: Version 1.3 must be present in the mappings, or be
xref:web/webmvc/mvc-config/api-version.adoc[configured as supported].
For request with version `"1.5"`:
- (1) matches as it matches any version
@ -490,10 +493,6 @@ versioned alternative was introduced. Therefore, even though an unversioned cont @@ -490,10 +493,6 @@ versioned alternative was introduced. Therefore, even though an unversioned cont
method is considered a match for any version, it is in fact given the lowest priority,
and is effectively superseded by any alternative controller method with a version.
NOTE: The above assumes the request version is a
xref:web/webmvc/mvc-config/api-version.adoc["supported" version], or otherwise it
would fail.
See xref:web/webmvc-versioning.adoc[API Versioning] for more details on underlying
infrastructure and support for API Versioning.

Loading…
Cancel
Save