Commit Graph

571 Commits

Author SHA1 Message Date
Brian Clozel c5f51aab67 Merge branch '6.1.x' 2024-08-22 09:32:11 +02:00
alfredo-toledano aca5db817d Fix link to core container introduction in ref docs
Closes gh-33417
2024-08-22 09:30:47 +02:00
rstoyanchev cef1b7ea6d Polishing in HTTP interface argument resolvers 2024-08-12 21:01:03 +03:00
Olga Maciaszek-Sharma 51de84e148 Reject null for non-optional arguments
Closes gh-33339
2024-08-12 21:01:03 +03:00
Sam Brannen 4f607b59a3 Improve document for SpEL Bean References 2024-08-10 16:44:17 +03:00
Sam Brannen eab96073da Document that SpEL expressions using bean references are not compilable
Closes gh-33363
2024-08-10 16:33:55 +03:00
Simon Baslé bf5e218b35 Add support for headers in `@HttpExchange`
On the client side, supports `name=value` pairs. Placeholders in values
are resolved by the `embeddedValueResolver`.
On the server side, additionally supports `name` and `!name` syntax.

Closes gh-33309
2024-08-09 18:02:16 +02:00
Stéphane Nicoll ea2c441008 Merge branch '6.1.x' 2024-08-09 09:52:19 +02:00
Stéphane Nicoll 7a250aa8ea Polish
See gh-33354
2024-08-09 09:52:06 +02:00
Stéphane Nicoll bd61da12b2 Merge branch '6.1.x' 2024-08-09 09:05:12 +02:00
Stéphane Nicoll df7ac9b308 Polish "Fix error codes in Customizing Validation Errors section"
See gh-33354
2024-08-09 09:03:05 +02:00
Gonçalo Silva 43217bdf06 Fix error codes in Customizing Validation Errors section
See gh-33354
2024-08-09 09:02:53 +02:00
Sam Brannen cd7c650941 Merge branch '6.1.x' 2024-08-08 17:16:19 +03:00
Robert Danczak a31945f8b6 Fix syntax error in RestClient documentation
Closes gh-33350
2024-08-08 17:15:27 +03:00
rstoyanchev e670c6b50a Documentation updates for fragment rendering
Closes gh-33195
2024-08-08 16:25:03 +03:00
rstoyanchev 0bac8d48a5 Polishing in view rendering documentation
See gh-33195
2024-08-08 16:25:03 +03:00
Stéphane Nicoll 4ceefa7501 Merge branch '6.1.x' 2024-08-08 11:41:53 +02:00
Paul-Christian Volkmer 7e4884fcfa Add missing Kotlin example for expectAll()
See gh-33341
2024-08-08 11:35:12 +02:00
Simon Baslé 1c893e6354 Add `@MockitoBeanSettings`, use MockitoSession with strict stubs default
This commit changes the way the `MockitoTestExecutionListener` sets up
mockito, now using the `MockitoSession` feature. Additionally, stubbing
now defaults to a STRICT mode which can be overruled with a newly
introduced annotation: `@MockitoBeanSettings`.

Closes gh-33318
2024-08-07 14:57:15 +02:00
Brian Clozel 38453910cd Add DatabaseClient bind variant for list of parameters
Prior to this commit, the `DatabaseClient` interface would allow batch
operations for binding parameters by their names and values. Positional
parameters did not have such equivalent.

This commit adds a new `bindValues(List<?>)` method variant for adding
multiple positional arguments in a single call and avoiding allocation
overhead when the parameters count is large.

Closes gh-33274
2024-07-29 14:07:15 +02:00
Stéphane Nicoll 46ba13b645 Review Caching infrastructure documentation
Closes gh-33288
2024-07-29 11:29:35 +02:00
Stéphane Nicoll de2335bee3 Merge branch '6.1.x' 2024-07-26 10:05:06 +02:00
Stéphane Nicoll ea665d776d Polish "Fix reference to configurePathMatching in code sample"
See gh-33277
2024-07-26 10:01:39 +02:00
sheip9 7a2fc2ff09 Fix reference to configurePathMatching in code sample
See gh-33277
2024-07-26 10:01:21 +02:00
Simon Baslé c92e043bbc Support multiple style of parsing/printing Durations
This commit introduces a notion of different styles for the formatting
of Duration.
The `@DurationFormat` annotation is added to ease selection of a style,
which are represented as DurationFormat.Style enum, as well as a
supported time unit represented as DurationFormat.Unit enum.

DurationFormatter has been retroffited to take such a Style,
optionally, at construction. The default is still the JDK style a.k.a.
ISO-8601.

This introduces the new SIMPLE style which uses a single number + a
short human-readable suffix. For instance "-3ms" or "2h".

This has the same semantics as the DurationStyle in Spring Boot and
is intended as a replacement for that feature, providing access to the
feature to projects that only depend on Spring Framework.

Finally, the `@Scheduled` annotation is improved by adding detection
of the style and parsing for the String versions of initial delay, fixed
delay and fixed rate.

See gh-22013
See gh-22474

Closes gh-30396
2024-07-23 11:56:48 +02:00
Stéphane Nicoll 2190c6ec79 Merge branch '6.1.x' 2024-07-21 11:42:39 +02:00
Stéphane Nicoll af8dc44469 Polish "Stop referring to STRUCT and ARRAY as they are deprecated"
See gh-33248
2024-07-21 11:39:16 +02:00
Tran Ngoc Nhan 955602bdbd Stop referring to STRUCT and ARRAY as they are deprecated
See gh-33248
2024-07-21 11:18:12 +02:00
Stéphane Nicoll 97411ddd55 Merge branch '6.1.x' 2024-07-20 11:53:31 +02:00
Stéphane Nicoll a3b737ed00 Polish "Update links in reference manual"
See gh-33245
2024-07-20 11:51:49 +02:00
Tran Ngoc Nhan 61d1fde797 Update links in reference manual
See gh-33245
2024-07-20 11:32:35 +02:00
Brian Clozel b701b26b07 Merge branch '6.1.x' 2024-07-19 17:23:14 +02:00
Brian Clozel 0bb309f433 Instrument @JmsListener session for response messages
Prior to this commit, the observation instrumentation for `@JmsListener`
annotated methods (implemented in `AbstractMessageListenerContainer`
would not instrument the JMS session using the Micrometer JMS support.
This means that response messages returned from the listener method
would be sent but no observation would be recorded. As a result, tracing
message properties would be also missing.

This commit ensures that the session provided to the listener method is
instrumented beforehand, if Micrometer is on the classpath and an
observation registry has been configured.

Fixes gh-33221
2024-07-19 17:17:18 +02:00
rstoyanchev 93d5be621b Merge branch '6.1.x' 2024-07-10 17:55:48 +01:00
rstoyanchev 611d3e5551 Correct type names in docs on Validation in WebFlux
Closes gh-33061
2024-07-10 17:55:19 +01:00
rstoyanchev b93b7e013a Add FragmentsRendering to documentation for return values
Closes gh-33162
2024-07-10 16:50:12 +01:00
Juergen Hoeller a9efe10428 Merge branch '6.1.x'
# Conflicts:
#	spring-beans/src/main/java/org/springframework/beans/factory/aot/DefaultBeanRegistrationCodeFragments.java
2024-07-10 15:16:40 +02:00
Juergen Hoeller 300f4585be Update spring.jdbc.getParameterType.ignore note for 6.1.2
See gh-25679
2024-07-10 15:15:26 +02:00
Stéphane Nicoll b7ec028149 Merge branch '6.1.x' 2024-07-08 16:52:01 +02:00
Hunhee Lee 3d8f1fb00f Harmonize phrasing in URI Encoding section
See gh-33166
2024-07-08 16:51:09 +02:00
Stéphane Nicoll 93587da394 Introduce ReflectiveScan
This commit allows `@Reflective` to be used on arbitrary types, not
only Spring beans. This makes the feature much more powerful as
components can be tagged directly.

Scanning happens during AOT processing (typically at build-time) when
`@ReflectiveScan` is used. Types do not need to have a particular
annotation, and types that can't be loaded are ignored.

This commit also exposes the infrastructure that does the scanning so
that custom code can do the scanning in an AOT contribution if they
don't want to rely on the annotation.

Closes gh-33132
2024-07-08 11:11:48 +02:00
Stéphane Nicoll f1658079a5 Polish documentation for RegisterReflection
See gh-29194
2024-07-06 09:31:12 +02:00
Sam Brannen abcad5dbcf Support property placeholders in @⁠Sql script paths
Prior to this commit, paths configured via the scripts attribute in
@⁠Sql were required to be final paths without dynamic placeholders;
however, being able to make script paths dependent on the current
environment can be useful in certain testing scenarios.

This commit introduces support for property placeholders (${...}) in
@⁠Sql script paths which will be replaced by properties available in
the Environment of the test's ApplicationContext.

Closes gh-33114
2024-07-03 17:16:53 +02:00
Sam Brannen a8e8897a00 Stop referring to old Spring versions in the reference manual 2024-07-01 18:37:46 +02:00
Sam Brannen e02cddd155 Delete obsolete documentation for JNDI mock support 2024-07-01 18:32:28 +02:00
Sam Brannen e427ac2683 Document parallel execution regarding @⁠MockitoBean & @⁠MockitoSpyBean 2024-07-01 17:08:09 +02:00
Sam Brannen 56fe857f1e Don't reference "Spring Framework 5.0" in parallel test execution section 2024-07-01 17:03:43 +02:00
Sam Brannen cc002875c4 Support fully-qualified factory method names in @⁠TestBean
Prior to this commit, @⁠TestBean factory methods had to be defined in
the test class, one of its superclasses, or in an implemented
interface. However, users may wish to define common factory methods in
external classes that can be shared easily across multiple test classes
simply by referencing an external method via a fully-qualified method
name.

To address that, this commit introduces support for referencing a
@⁠TestBean factory method via its fully-qualified method name following
the syntax <fully-qualified class name>#<method name>.

Closes gh-33125
2024-06-30 21:16:04 +02:00
Sam Brannen b64edb2d2a Update Content-Type based on encoding in MVC FreeMarkerView
Closes gh-33119
2024-06-29 17:12:48 +02:00
Sam Brannen e1567b93c2 Merge branch '6.1.x' 2024-06-27 11:40:16 +02:00