Skip to content

Commit 7e79d1f

Browse files
committed
Merge branch '3.1.x'
Closes gh-38289
2 parents 780c80f + eaaf977 commit 7e79d1f

22 files changed

+49
-49
lines changed

Diff for: spring-boot-project/spring-boot-docs/build.gradle

-1
Original file line numberDiff line numberDiff line change
@@ -332,7 +332,6 @@ tasks.withType(org.asciidoctor.gradle.jvm.AbstractAsciidoctorTask) {
332332
"spring-boot-version": project.version,
333333
"spring-data-commons-version": versionConstraints["org.springframework.data:spring-data-commons"],
334334
"spring-data-couchbase-version": versionConstraints["org.springframework.data:spring-data-couchbase"],
335-
"spring-data-envers-version": versionConstraints["org.springframework.data:spring-data-envers"],
336335
"spring-data-jdbc-version": versionConstraints["org.springframework.data:spring-data-jdbc"],
337336
"spring-data-jpa-version": versionConstraints["org.springframework.data:spring-data-jpa"],
338337
"spring-data-mongodb-version": versionConstraints["org.springframework.data:spring-data-mongodb"],

Diff for: spring-boot-project/spring-boot-docs/src/docs/asciidoc/actuator/metrics.adoc

+3-3
Original file line numberDiff line numberDiff line change
@@ -755,7 +755,7 @@ Auto-configuration enables the instrumentation of all requests handled by Spring
755755
By default, metrics are generated with the name, `http.server.requests`.
756756
You can customize the name by setting the configprop:management.observations.http.server.requests.name[] property.
757757

758-
See the {spring-framework-docs}/integration.html#integration.observability.http-server.servlet[Spring Framework reference documentation for more information on produced observations].
758+
See the {spring-framework-docs}/integration/observability.html#observability.http-server.servlet[Spring Framework reference documentation for more information on produced observations].
759759

760760
To add to the default tags, provide a `@Bean` that extends `DefaultServerRequestObservationConvention` from the `org.springframework.http.server.observation` package.
761761
To replace the default tags, provide a `@Bean` that implements `ServerRequestObservationConvention`.
@@ -775,7 +775,7 @@ Auto-configuration enables the instrumentation of all requests handled by Spring
775775
By default, metrics are generated with the name, `http.server.requests`.
776776
You can customize the name by setting the configprop:management.observations.http.server.requests.name[] property.
777777

778-
See the {spring-framework-docs}/integration.html#integration.observability.http-server.reactive[Spring Framework reference documentation for more information on produced observations].
778+
See the {spring-framework-docs}/integration/observability.html#observability.http-server.reactive[Spring Framework reference documentation for more information on produced observations].
779779

780780
To add to the default tags, provide a `@Bean` that extends `DefaultServerRequestObservationConvention` from the `org.springframework.http.server.reactive.observation` package.
781781
To replace the default tags, provide a `@Bean` that implements `ServerRequestObservationConvention`.
@@ -830,7 +830,7 @@ You can also manually apply the customizers responsible for this instrumentation
830830
By default, metrics are generated with the name, `http.client.requests`.
831831
You can customize the name by setting the configprop:management.observations.http.client.requests.name[] property.
832832

833-
See the {spring-framework-docs}/integration.html#integration.observability.http-client[Spring Framework reference documentation for more information on produced observations].
833+
See the {spring-framework-docs}/integration/observability.html#observability.http-client[Spring Framework reference documentation for more information on produced observations].
834834

835835
To customize the tags when using `RestTemplate`, provide a `@Bean` that implements `ClientRequestObservationConvention` from the `org.springframework.http.client.observation` package.
836836
To customize the tags when using `WebClient`, provide a `@Bean` that implements `ClientRequestObservationConvention` from the `org.springframework.web.reactive.function.client` package.

Diff for: spring-boot-project/spring-boot-docs/src/docs/asciidoc/attributes.adoc

-1
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,6 @@
6565
:spring-data-elasticsearch: https://spring.io/projects/spring-data-elasticsearch
6666
:spring-data-elasticsearch-docs: https://docs.spring.io/spring-data/elasticsearch/docs/current/reference/html/
6767
:spring-data-envers: https://spring.io/projects/spring-data-envers
68-
:spring-data-envers-doc: https://docs.spring.io/spring-data/envers/docs/{spring-data-envers-version}/reference/html/
6968
:spring-data-gemfire: https://spring.io/projects/spring-data-gemfire
7069
:spring-data-geode: https://spring.io/projects/spring-data-geode
7170
:spring-data-jpa: https://spring.io/projects/spring-data-jpa

Diff for: spring-boot-project/spring-boot-docs/src/docs/asciidoc/data/sql.adoc

+1-1
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,7 @@ To use Spring Data Envers, make sure your repository extends from `RevisionRepos
260260

261261
include::code:CountryRepository[]
262262

263-
NOTE: For more details, check the {spring-data-envers-doc}[Spring Data Envers reference documentation].
263+
NOTE: For more details, check the {spring-data-jpa-docs}/#envers[Spring Data Envers reference documentation].
264264

265265

266266

Diff for: spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/aop.adoc

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[[features.aop]]
22
== Aspect-Oriented Programming
33
Spring Boot provides auto-configuration for aspect-oriented programming (AOP).
4-
You can learn more about AOP with Spring in the {spring-framework-docs}/core.html#aop[Spring Framework reference documentation].
4+
You can learn more about AOP with Spring in the {spring-framework-docs}/core/aop-api.html[Spring Framework reference documentation].
55

66
By default, Spring Boot's auto-configuration configures Spring AOP to use CGLib proxies.
77
To use JDK proxies instead, set `configprop:spring.aop.proxy-target-class` to `false`.

Diff for: spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/developing-auto-configuration.adoc

+1-1
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ This condition will not match for applications that are run with an embedded web
136136

137137
[[features.developing-auto-configuration.condition-annotations.spel-conditions]]
138138
==== SpEL Expression Conditions
139-
The `@ConditionalOnExpression` annotation lets configuration be included based on the result of a {spring-framework-docs}/core.html#expressions[SpEL expression].
139+
The `@ConditionalOnExpression` annotation lets configuration be included based on the result of a {spring-framework-docs}/core/expressions.html[SpEL expression].
140140

141141
NOTE: Referencing a bean in the expression will cause that bean to be initialized very early in context refresh processing.
142142
As a result, the bean won't be eligible for post-processing (such as configuration properties binding) and its state may be incomplete.

Diff for: spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/kotlin.adoc

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
https://kotlinlang.org[Kotlin] is a statically-typed language targeting the JVM (and other platforms) which allows writing concise and elegant code while providing {kotlin-docs}java-interop.html[interoperability] with existing libraries written in Java.
44

55
Spring Boot provides Kotlin support by leveraging the support in other Spring projects such as Spring Framework, Spring Data, and Reactor.
6-
See the {spring-framework-docs}/languages.html#kotlin[Spring Framework Kotlin support documentation] for more information.
6+
See the {spring-framework-docs}/languages/kotlin.html[Spring Framework Kotlin support documentation] for more information.
77

88
The easiest way to start with Spring Boot and Kotlin is to follow https://spring.io/guides/tutorials/spring-boot-kotlin/[this comprehensive tutorial].
99
You can create new Kotlin projects by using https://start.spring.io/#!language=kotlin[start.spring.io].

Diff for: spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/logging.adoc

+2-2
Original file line numberDiff line numberDiff line change
@@ -446,7 +446,7 @@ Profile sections are supported anywhere within the `<configuration>` element.
446446
Use the `name` attribute to specify which profile accepts the configuration.
447447
The `<springProfile>` tag can contain a profile name (for example `staging`) or a profile expression.
448448
A profile expression allows for more complicated profile logic to be expressed, for example `production & (eu-central | eu-west)`.
449-
Check the {spring-framework-docs}/core.html#beans-definition-profiles-java[Spring Framework reference guide] for more details.
449+
Check the {spring-framework-docs}/core/beans/environment.html#beans-definition-profiles-java[Spring Framework reference guide] for more details.
450450
The following listing shows three sample profiles:
451451

452452
[source,xml,subs="verbatim",indent=0]
@@ -511,7 +511,7 @@ Profile sections are supported anywhere within the `<Configuration>` element.
511511
Use the `name` attribute to specify which profile accepts the configuration.
512512
The `<SpringProfile>` tag can contain a profile name (for example `staging`) or a profile expression.
513513
A profile expression allows for more complicated profile logic to be expressed, for example `production & (eu-central | eu-west)`.
514-
Check the {spring-framework-docs}/core.html#beans-definition-profiles-java[Spring Framework reference guide] for more details.
514+
Check the {spring-framework-docs}/core/beans/environment.html#beans-definition-profiles-java[Spring Framework reference guide] for more details.
515515
The following listing shows three sample profiles:
516516

517517
[source,xml,subs="verbatim",indent=0]

Diff for: spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/spring-application.adoc

+1-1
Original file line numberDiff line numberDiff line change
@@ -356,7 +356,7 @@ TIP: If you want to know on which HTTP port the application is running, get the
356356
=== Application Startup tracking
357357
During the application startup, the `SpringApplication` and the `ApplicationContext` perform many tasks related to the application lifecycle,
358358
the beans lifecycle or even processing application events.
359-
With {spring-framework-api}/core/metrics/ApplicationStartup.html[`ApplicationStartup`], Spring Framework {spring-framework-docs}/core.html#context-functionality-startup[allows you to track the application startup sequence with `StartupStep` objects].
359+
With {spring-framework-api}/core/metrics/ApplicationStartup.html[`ApplicationStartup`], Spring Framework {spring-framework-docs}/core/beans/context-introduction.html#context-functionality-startup[allows you to track the application startup sequence with `StartupStep` objects].
360360
This data can be collected for profiling purposes, or just to have a better understanding of an application startup process.
361361

362362
You can choose an `ApplicationStartup` implementation when setting up the `SpringApplication` instance.

Diff for: spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/testing.adoc

+10-10
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ To use the vintage engine, add a dependency on `junit-vintage-engine`, as shown
3535
The `spring-boot-starter-test` "`Starter`" (in the `test` `scope`) contains the following provided libraries:
3636

3737
* https://junit.org/junit5/[JUnit 5]: The de-facto standard for unit testing Java applications.
38-
* {spring-framework-docs}/testing.html#integration-testing[Spring Test] & Spring Boot Test: Utilities and integration test support for Spring Boot applications.
38+
* {spring-framework-docs}/testing/integration.html[Spring Test] & Spring Boot Test: Utilities and integration test support for Spring Boot applications.
3939
* https://assertj.github.io/doc/[AssertJ]: A fluent assertion library.
4040
* https://github.com/hamcrest/JavaHamcrest[Hamcrest]: A library of matcher objects (also known as constraints or predicates).
4141
* https://site.mockito.org/[Mockito]: A Java mocking framework.
@@ -60,7 +60,7 @@ It is useful to be able to perform integration testing without requiring deploym
6060
The Spring Framework includes a dedicated test module for such integration testing.
6161
You can declare a dependency directly to `org.springframework:spring-test` or use the `spring-boot-starter-test` "`Starter`" to pull it in transitively.
6262

63-
If you have not used the `spring-test` module before, you should start by reading the {spring-framework-docs}/testing.html#testing[relevant section] of the Spring Framework reference documentation.
63+
If you have not used the `spring-test` module before, you should start by reading the {spring-framework-docs}/testing.html[relevant section] of the Spring Framework reference documentation.
6464

6565

6666

@@ -199,13 +199,13 @@ include::code:MyApplicationArgumentTests[]
199199
==== Testing With a Mock Environment
200200
By default, `@SpringBootTest` does not start the server but instead sets up a mock environment for testing web endpoints.
201201

202-
With Spring MVC, we can query our web endpoints using {spring-framework-docs}/testing.html#spring-mvc-test-framework[`MockMvc`] or `WebTestClient`, as shown in the following example:
202+
With Spring MVC, we can query our web endpoints using {spring-framework-docs}/testing/spring-mvc-test-framework.html[`MockMvc`] or `WebTestClient`, as shown in the following example:
203203

204204
include::code:MyMockMvcTests[]
205205

206206
TIP: If you want to focus only on the web layer and not start a complete `ApplicationContext`, consider <<features#features.testing.spring-boot-applications.spring-mvc-tests,using `@WebMvcTest` instead>>.
207207

208-
With Spring WebFlux endpoints, you can use {spring-framework-docs}/testing.html#webtestclient-tests[`WebTestClient`] as shown in the following example:
208+
With Spring WebFlux endpoints, you can use {spring-framework-docs}/testing/webtestclient.html[`WebTestClient`] as shown in the following example:
209209

210210
include::code:MyMockWebTestClientTests[]
211211

@@ -227,7 +227,7 @@ If you need to start a full running server, we recommend that you use random por
227227
If you use `@SpringBootTest(webEnvironment=WebEnvironment.RANDOM_PORT)`, an available port is picked at random each time your test runs.
228228

229229
The `@LocalServerPort` annotation can be used to <<howto#howto.webserver.discover-port,inject the actual port used>> into your test.
230-
For convenience, tests that need to make REST calls to the started server can additionally `@Autowire` a {spring-framework-docs}/testing.html#webtestclient-tests[`WebTestClient`], which resolves relative links to the running server and comes with a dedicated API for verifying responses, as shown in the following example:
230+
For convenience, tests that need to make REST calls to the started server can additionally `@Autowire` a {spring-framework-docs}/testing/webtestclient.html[`WebTestClient`], which resolves relative links to the running server and comes with a dedicated API for verifying responses, as shown in the following example:
231231

232232
include::code:MyRandomPortWebTestClientTests[]
233233

@@ -420,7 +420,7 @@ TIP: If you need to register extra components, such as Jackson `Module`, you can
420420

421421
Often, `@WebFluxTest` is limited to a single controller and used in combination with the `@MockBean` annotation to provide mock implementations for required collaborators.
422422

423-
`@WebFluxTest` also auto-configures {spring-framework-docs}/testing.html#webtestclient[`WebTestClient`], which offers a powerful way to quickly test WebFlux controllers without needing to start a full HTTP server.
423+
`@WebFluxTest` also auto-configures {spring-framework-docs}/testing/webtestclient.html[`WebTestClient`], which offers a powerful way to quickly test WebFlux controllers without needing to start a full HTTP server.
424424

425425
TIP: You can also auto-configure `WebTestClient` in a non-`@WebFluxTest` (such as `@SpringBootTest`) by annotating it with `@AutoConfigureWebTestClient`.
426426
The following example shows a class that uses both `@WebFluxTest` and a `WebTestClient`:
@@ -560,7 +560,7 @@ Regular `@Component` and `@ConfigurationProperties` beans are not scanned when t
560560
TIP: A list of the auto-configuration settings that are enabled by `@DataJpaTest` can be <<test-auto-configuration#appendix.test-auto-configuration,found in the appendix>>.
561561

562562
By default, data JPA tests are transactional and roll back at the end of each test.
563-
See the {spring-framework-docs}/testing.html#testcontext-tx-enabling-transactions[relevant section] in the Spring Framework Reference Documentation for more details.
563+
See the {spring-framework-docs}/testing/testcontext-framework/tx.html#testcontext-tx-enabling-transactions[relevant section] in the Spring Framework Reference Documentation for more details.
564564
If that is not what you want, you can disable transaction management for a test or for the whole class as follows:
565565

566566
include::code:MyNonTransactionalTests[]
@@ -592,7 +592,7 @@ Regular `@Component` and `@ConfigurationProperties` beans are not scanned when t
592592
TIP: A list of the auto-configurations that are enabled by `@JdbcTest` can be <<test-auto-configuration#appendix.test-auto-configuration,found in the appendix>>.
593593

594594
By default, JDBC tests are transactional and roll back at the end of each test.
595-
See the {spring-framework-docs}/testing.html#testcontext-tx-enabling-transactions[relevant section] in the Spring Framework Reference Documentation for more details.
595+
See the {spring-framework-docs}/testing/testcontext-framework/tx.html#testcontext-tx-enabling-transactions[relevant section] in the Spring Framework Reference Documentation for more details.
596596
If that is not what you want, you can disable transaction management for a test or for the whole class, as follows:
597597

598598
include::code:MyTransactionalTests[]
@@ -612,7 +612,7 @@ Only `AbstractJdbcConfiguration` subclasses are scanned when the `@DataJdbcTest`
612612
TIP: A list of the auto-configurations that are enabled by `@DataJdbcTest` can be <<test-auto-configuration#appendix.test-auto-configuration,found in the appendix>>.
613613

614614
By default, Data JDBC tests are transactional and roll back at the end of each test.
615-
See the {spring-framework-docs}/testing.html#testcontext-tx-enabling-transactions[relevant section] in the Spring Framework Reference Documentation for more details.
615+
See the {spring-framework-docs}/testing/testcontext-framework/tx.html#testcontext-tx-enabling-transactions[relevant section] in the Spring Framework Reference Documentation for more details.
616616
If that is not what you want, you can disable transaction management for a test or for the whole test class as <<features#features.testing.spring-boot-applications.autoconfigured-jdbc,shown in the JDBC example>>.
617617

618618
If you prefer your test to run against a real database, you can use the `@AutoConfigureTestDatabase` annotation in the same way as for `@DataJpaTest`.
@@ -688,7 +688,7 @@ The following example shows a typical setup for using Neo4J tests in Spring Boot
688688
include::code:propagation/MyDataNeo4jTests[]
689689

690690
By default, Data Neo4j tests are transactional and roll back at the end of each test.
691-
See the {spring-framework-docs}/testing.html#testcontext-tx-enabling-transactions[relevant section] in the Spring Framework Reference Documentation for more details.
691+
See the {spring-framework-docs}/testing/testcontext-framework/tx.html#testcontext-tx-enabling-transactions[relevant section] in the Spring Framework Reference Documentation for more details.
692692
If that is not what you want, you can disable transaction management for a test or for the whole class, as follows:
693693

694694
include::code:nopropagation/MyDataNeo4jTests[]

Diff for: spring-boot-project/spring-boot-docs/src/docs/asciidoc/getting-started/first-application.adoc

+1-1
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,7 @@ It tells Spring that any HTTP request with the `/` path should be mapped to the
270270
The `@RestController` annotation tells Spring to render the resulting string directly back to the caller.
271271

272272
TIP: The `@RestController` and `@RequestMapping` annotations are Spring MVC annotations (they are not specific to Spring Boot).
273-
See the {spring-framework-docs}/web.html#mvc[MVC section] in the Spring Reference Documentation for more details.
273+
See the {spring-framework-docs}/web/webmvc.html[MVC section] in the Spring Reference Documentation for more details.
274274

275275

276276

Diff for: spring-boot-project/spring-boot-docs/src/docs/asciidoc/howto/webserver.adoc

+1-1
Original file line numberDiff line numberDiff line change
@@ -409,7 +409,7 @@ There are also non-standard headers, like `X-Forwarded-Host`, `X-Forwarded-Port`
409409
If the proxy adds the commonly used `X-Forwarded-For` and `X-Forwarded-Proto` headers, setting `server.forward-headers-strategy` to `NATIVE` is enough to support those.
410410
With this option, the Web servers themselves natively support this feature; you can check their specific documentation to learn about specific behavior.
411411

412-
If this is not enough, Spring Framework provides a {spring-framework-docs}/web.html#filters-forwarded-headers[ForwardedHeaderFilter] for the servlet stack and a {spring-framework-docs}/web-reactive.html#webflux-forwarded-headers[ForwardedHeaderTransformer] for the reactive stack.
412+
If this is not enough, Spring Framework provides a {spring-framework-docs}/web/webmvc/filters.html#filters-forwarded-headers[ForwardedHeaderFilter] for the servlet stack and a {spring-framework-docs}/web/webflux/reactive-spring.html#webflux-forwarded-headers[ForwardedHeaderTransformer] for the reactive stack.
413413
You can use them in your application by setting configprop:server.forward-headers-strategy[] to `FRAMEWORK`.
414414

415415
TIP: If you are using Tomcat and terminating SSL at the proxy, configprop:server.tomcat.redirect-context-root[] should be set to `false`.

0 commit comments

Comments
 (0)