Commit Graph

34229 Commits

Author SHA1 Message Date
Sam Brannen 38cf4ab3fc Make RetryTemplate timeout tests more robust
See gh-35963
2025-12-09 17:03:41 +01:00
Sam Brannen 2137ec70d2 Make @​Retryable timeout tests more robust
See gh-35963
2025-12-09 16:56:53 +01:00
Sam Brannen 61201db704 Improve error message for preemptive timeout in RetryTemplate
The error message in such cases now indicates that the retry process
is being aborted preemptively due to pending sleep time.

For example:

  Retry policy for operation 'myMethod' would exceed timeout (5 ms) due
  to pending sleep time (10 ms); preemptively aborting execution

See gh-35963
2025-12-09 16:46:44 +01:00
Sam Brannen 2643c6212f Delete obsolete test code 2025-12-09 16:39:20 +01:00
Sam Brannen b46328a000 Fix broken assertions in @​Retryable timeout tests
See gh-35963
2025-12-09 16:38:05 +01:00
Sam Brannen cc4c693db7 Log RetryException for @Retryable methods
To improve diagnostics, this commit logs a DEBUG message including the
RetryException thrown by RetryTemplate when it's used behind the scenes
for @Retryable method invocations.

Closes gh-35983
2025-12-09 16:24:00 +01:00
Sam Brannen a206ea8b12 Make @​Retryable timeout tests more robust
See gh-35963
2025-12-09 16:10:43 +01:00
Sam Brannen 9f1d9fe82c Support timeouts in @​Retryable and RetryPolicy
Specifically, this commit introduces:

- timeout and timeoutString attributes in @​Retryable

- a default getTimeout() method in RetryPolicy

- a timeout() method in RetryPolicy.Builder

- an onRetryPolicyTimeout() callback in RetryListener

- support for checking exceeded timeouts in RetryTemplate (also used
  for imperative method invocations with @​Retryable)

- support for checking exceeded timeouts in reactive pipelines with
  @​Retryable

Closes gh-35963
2025-12-09 14:06:35 +01:00
Juergen Hoeller ab33000750 Do not keep target connection after failed settings
Includes aligned setReadOnly exception suppression.

Closes gh-35980
2025-12-09 12:59:27 +01:00
Juergen Hoeller e2ab9cd5da Use composed cache key for different SmartFactoryBean object types
Closes gh-35974
2025-12-09 12:59:19 +01:00
Sam Brannen 103db5429a Use AtomicIntegerAssert 2025-12-09 12:43:18 +01:00
Sam Brannen 68f8139206 Polishing 2025-12-08 17:11:38 +01:00
Sam Brannen a9da900b5b Fix test logic 2025-12-08 17:10:27 +01:00
Brian Clozel e7e4b3559a Polishing contribution
Closes gh-35978
2025-12-08 16:10:20 +01:00
Johnny Lim feb77f924a Fix SubscriberInputStream.resume()
See gh-35978

Signed-off-by: Johnny Lim <izeye@naver.com>
2025-12-08 16:10:05 +01:00
Brian Clozel 12c3dc0cbe Fix compressed HEAD requests handling in JDK client
Prior to this commit, the `JdkClientHttpRequestFactory` would support
decompressing gziped/deflate encoded response bodies but would fail if
the response has no body but has a "Content-Encoding" response header.
This happens as a response to HEAD requests.

This commit ensures that only responses with actual message bodies are
decompressed.

Fixes gh-35966
2025-12-08 15:23:55 +01:00
Juergen Hoeller df27627516 Accept assignable match for covariant return type
See gh-35936
2025-12-08 12:41:43 +01:00
Sam Brannen 939aa84214 Revise type-level nullability in ConvertingComparator
This commit revises the type-level nullability declaration in
ConvertingComparator in order to adapt to recent nullability changes in
Converter.

This commit also revises the workaround in commit 53d9ba879d.

See gh-35947
2025-12-08 11:22:14 +01:00
Brian Clozel 9f77f401ad Complete Propagator.Getter implementation
As of Micrometer Tracing 1.6.0, the `Propagator.Getter` interface
adds a new `getAll` method with a default implementation return a
singleton collection.

This commit adds the missing implementation override in both Servlet and
Reactor web server contexts.

Fixes gh-35965
2025-12-08 11:07:30 +01:00
Sébastien Deleuze f19f1a667c Add support for package-private BeanRegistrar
Closes gh-35803
2025-12-05 17:04:51 +01:00
Sébastien Deleuze 69207c6c16 Introduce BeanFactoryInitializationCode#getClassName
See gh-35803
2025-12-05 17:04:51 +01:00
Sébastien Deleuze f61832ecb8 Fix indentation 2025-12-05 17:04:51 +01:00
Juergen Hoeller 14790493f4 Upgrade to Log4J 2.25.2, Groovy 5.0.3, Jetty 12.1.5, Jetty Reactive HttpClient 4.1.4, Checkstyle 12.2 2025-12-05 17:03:57 +01:00
Juergen Hoeller 53d9ba879d Suppress NullAway warning for nullable Annotation return value 2025-12-05 16:53:24 +01:00
Juergen Hoeller 9d2d9ae0ff Reinstate stopOrder test
See gh-35964
2025-12-05 16:30:00 +01:00
Juergen Hoeller c74af40288 Stop already started Lifecycle beans on cancelled refresh
Closes gh-35964
2025-12-05 16:14:27 +01:00
Juergen Hoeller 196c1dd51c Handle absolute file URLs in getClassPathManifestEntriesFromJar
Closes gh-35682
2025-12-05 16:13:30 +01:00
Sam Brannen 44689b9ec0 Simplify RestTestClientIntegrationTests and remove duplicate field 2025-12-05 16:00:42 +01:00
Sam Brannen b916dc962e Document that annotations which reference types not present are ignored
Add warnings to the class-level Javadoc for MergedAnnotations,
AnnotatedTypeMetadata, AnnotationMetadata, and MethodMetadata to point
out that annotations may be ignored if their attributes reference types
that are not present in the classpath.

Closes gh-35959
2025-12-05 15:50:02 +01:00
Tran Ngoc Nhan 87d0113b25 Correct Reactive Libraries reference link
Signed-off-by: Tran Ngoc Nhan <ngocnhan.tran1996@gmail.com>
2025-12-05 14:09:02 +00:00
rstoyanchev cee185ce3b Append query on redirect in UrlHandlerFilter
Closes gh-35873
2025-12-05 12:35:32 +00:00
rstoyanchev e45727d4fa Polishing in InMemoryWebSessionStore
Closes gh-35866
2025-12-05 12:29:11 +00:00
Mengqi Xu bc088ebdef Allow configuring default maxIdleTime on InMemoryWebSessionStore.
See gh-35866

Signed-off-by: Mengqi Xu <2663479778@qq.com>
2025-12-05 12:28:37 +00:00
Sam Brannen f1cf91c9f9 Polishing 2025-12-05 12:22:24 +01:00
Sébastien Deleuze d36475cb4c Use flexible generic type level nullability in Converter
Allow defining converters that return non-null values by
leveraging flexible generic type level nullability in
org.springframework.core.convert.converter.Converter.

Closes gh-35947
2025-12-05 07:28:52 +01:00
Sébastien Deleuze 8b6d7e0da7 Refine KotlinDetector#hasSerializableAnnotation
Refine KotlinDetector#hasSerializableAnnotation in order to detect
deeply nested generic types.

Closes gh-35960
2025-12-04 15:54:03 +01:00
Sam Brannen 0a86a7e3a8 Use == instead of instanceof for primitive array type checks
Closes gh-35962
2025-12-04 15:06:08 +01:00
rstoyanchev 8edde374bb Lower bad requests to DEBUG level in AbstractHandshakeHandler
Closes gh-35930
2025-12-04 09:07:55 +00:00
rstoyanchev 35b58cd0ee Avoid http - web.utils package cycle
Closes gh-35952
2025-12-04 09:07:55 +00:00
Juergen Hoeller dfc900c7c4 Add @Override to existing resetCaches() methods
See gh-35845
See gh-35840
2025-12-04 07:09:21 +01:00
Juergen Hoeller 07c0213f20 Polishing 2025-12-04 00:12:31 +01:00
Juergen Hoeller 667851c0fa Avoid computeIfAbsent for createMappings which calls back into same map
Closes gh-35944
2025-12-04 00:12:22 +01:00
Juergen Hoeller 96aadc2b12 Add resetCaches() method to general CacheManager interface
Closes gh-35845
See gh-35840
2025-12-04 00:12:13 +01:00
Sam Brannen 2c6ccaea05 Use simple type name for meta-annotation in log message
In contrast to the previous commit, a warning similar to the following
is now logged in such cases.

WARN o.s.c.a.MergedAnnotation -
  Failed to introspect meta-annotation @MyAnnotation on class
  example.Config: java.lang.TypeNotPresentException:
  Type example.OptionalDependency not present

See gh-35927
2025-12-03 17:15:53 +01:00
Sam Brannen 62d09be2ae Log warning if meta-annotation is ignored due to types not present
Prior to this commit, if a meta-annotation could not be loaded because
its attributes referenced types not present in the classpath, the
meta-annotation was silently ignored.

To improve diagnostics for such use cases, this commit introduces WARN
support in IntrospectionFailureLogger and revises AttributeMethods.canLoad()
to log a warning if a meta-annotation is ignored due to an exception
thrown while attempting to load its attributes.

For example, a warning similar to the following is now logged in such
cases.

WARN o.s.c.a.MergedAnnotation -
  Failed to introspect meta-annotation @example.MyAnnotation on class
  example.Config: java.lang.TypeNotPresentException:
  Type example.OptionalDependency not present

This commit also improves log messages in AnnotationTypeMappings.

Closes gh-35927
2025-12-03 17:00:24 +01:00
Stéphane Nicoll 47f65b3dff Use correct product name for IntelliJ IDEA 2025-12-02 16:54:56 +01:00
Sam Brannen c7e24a5c26 Update antora-extensions to 1.14.7
Closes gh-35949
2025-12-02 15:33:56 +01:00
Sam Brannen a493bd959d Fix nullability in TestContextAnnotationUtils.findAnnotationDescriptor() 2025-12-02 15:32:32 +01:00
Juergen Hoeller 92e9543ad4 Select method with resolved return type match (among multiple candidates)
Removes unnecessary array type check for parameters of candidate methods.

Closes gh-35936
2025-12-01 23:25:59 +01:00
ivonaest 68231aa08c Upgrade json-path to 2.10.0
Closes gh-35924
Signed-off-by: ivonaest <ivona.cvija@est.tech>
2025-12-01 15:27:45 +01:00