Commit Graph

31891 Commits

Author SHA1 Message Date
Dmitry Sulman a6f3f18d89 Allow supertypes in ContentResultMatchersDsl matchers
Closes gh-34542
Signed-off-by: Dmitry Sulman <dmitry.sulman@gmail.com>
2025-03-07 09:29:48 +01:00
Sam Brannen 8334cb1abb Revise tests to better express intent 2025-03-06 17:32:32 +01:00
Sam Brannen 2d88f18bf1 Update Javadoc 2025-03-06 16:26:40 +01:00
Sam Brannen 15a6641677 Clean up warnings in Gradle build 2025-03-06 16:26:32 +01:00
Juergen Hoeller 63c8e7cb5d Restore lenient matching of unresolved nested bound
Closes gh-34541
2025-03-06 15:44:12 +01:00
Sam Brannen c5ecc50bfe Document wrapping behavior for TestExecutionListener callbacks
Closes gh-34422
2025-03-06 13:31:23 +01:00
Sam Brannen 0fd94f1b9f Polishing 2025-03-06 13:30:20 +01:00
Juergen Hoeller 2472126475 Add fallback to pre-6.2.3 behavior for unresolvable generics
Closes gh-34535
2025-03-05 22:45:22 +01:00
Juergen Hoeller f3b50c9a58 Ignore null beans in SimpleAutowireCandidateResolver.resolveAutowireCandidates
Closes gh-34543
2025-03-05 22:44:09 +01:00
Sam Brannen 0a6e666857 Ensure GenericTypeResolverTests compiles with Eclipse compiler 2025-03-05 14:07:52 +01:00
Juergen Hoeller 403362fe3c Polishing 2025-03-04 18:44:56 +01:00
Juergen Hoeller 534f123fe8 Add explicit FileSystemResource path check for trailing slash
Closes gh-34509
2025-03-04 18:44:25 +01:00
Sam Brannen e421104cf3 Supply RuntimeHints to an AotContextLoader
This commit introduces a new loadContextForAotProcessing(...) variant
in AotContextLoader which accepts a RuntimeHints argument. This new
method is an interface default method which delegates to the existing
loadContextForAotProcessing(MergedContextConfiguration) variant for
backward compatibility.

In addition, the original loadContextForAotProcessing(...) variant is
now deprecated and has been converted to an interface default method
which throws an UnsupportedOperationException.

Note, however, that the framework now only invokes the new
loadContextForAotProcessing(...) variant within TestContextAotGenerator.

Closes gh-34513
2025-03-03 17:39:56 +01:00
Sam Brannen adfeba23e0 Polishing 2025-03-03 17:39:47 +01:00
Sam Brannen 7789e12575 Polishing 2025-03-03 15:04:42 +01:00
Sam Brannen 30d793cefe Revise deprecation of SqlQuery.rowsExpected
Closes gh-34526
2025-03-03 14:33:19 +01:00
Yanming Zhou 78cc5df748 Deprecate unused "rowsExpected" property of SqlQuery for removal
See gh-34526

Signed-off-by: Yanming Zhou <zhouyanming@gmail.com>
2025-03-03 14:33:14 +01:00
Juergen Hoeller 5ffaea7a43 Avoid JarURLConnection resource leak in AbstractFileResolvingResource.exists()
Closes gh-34528
2025-03-03 13:32:51 +01:00
Brian Clozel 1633ad24f3 Ignore nohttp check on buildSrc/build 2025-03-03 11:23:21 +01:00
Rhett CfZhuang 5faf2ed7f4 Fix missing Partitioned cookie support in reactive HTTP clients
This commit adds support for the Partitioned cookie attribute in the
reactive HTTP clients that support this: Reactor and HttpComponents.

Closes gh-34521

Signed-off-by: Rhett CfZhuang <dark.momo985@gmail.com>
[brian.clozel@broadcom.com: rework tests and support HttpComponents]
Signed-off-by: Brian Clozel <brian.clozel@broadcom.com>
2025-03-03 11:23:13 +01:00
Juergen Hoeller d2733cea36 Notify lenientCreationFinished condition after locked creation as well
Closes gh-34522
2025-03-01 22:20:23 +01:00
Johnny Lim 108caea385 Use ORDER constant in MockitoResetTestExecutionListener
See gh-34404
Closes gh-34445

Signed-off-by: Johnny Lim <izeye@naver.com>
2025-03-01 13:35:46 +01:00
rstoyanchev 7e9ac120ac Deprecate UrlPathHelper in ServletWebSocketHandlerRegistry
Closes gh-34508
2025-02-28 14:39:29 +00:00
Juergen Hoeller c64dae3623 Avoid getTargetConnection call on transaction-aware Connection close
Closes gh-34484
2025-02-28 14:12:51 +01:00
Juergen Hoeller 559ea6c480 Defensively call isShutdown method for executor description
Closes gh-34514
2025-02-28 14:11:57 +01:00
Tran Ngoc Nhan 34315fc20f Fix web and webflux reference links
Closes gh-34517
Signed-off-by: Tran Ngoc Nhan <ngocnhan.tran1996@gmail.com>
2025-02-28 12:06:11 +01:00
Juergen Hoeller 3bb4795d43 Resolve variable bounds at outermost recursion level only
Closes gh-34504
2025-02-27 22:51:41 +01:00
Ryan Prayogo aae2952a32 Replace DefaultKeyGenerator with SimpleKeyGenerator
DefaultKeyGenerator has been deprecated and replaced with SimpleKeyGenerator

Signed-off-by: Ryan Prayogo <57620+ryanprayogo@users.noreply.github.com>
2025-02-27 18:53:10 +01:00
rstoyanchev f62251aebd Avoid pathVar-requestParam name collision
Closes gh-34499
2025-02-27 14:34:26 +00:00
rstoyanchev f92f9c1d5b Fix handling of timeout in SseEmitter
Closes gh-34426
2025-02-27 14:34:26 +00:00
Sam Brannen 2b38c00656 Upgrade to Gradle 8.13
Closes gh-34495
2025-02-26 15:26:49 +01:00
Juergen Hoeller 06721ba6c0 Lenient fallback when cached WeakReference returns null
Closes gh-34423
2025-02-26 10:24:24 +01:00
Brian Clozel b6a5402d88 Fix multiple Content-Language values in MockHttpServletResponse
Prior to this commit, `MockHttpServletResponse` would only support
adding a `Content-Language` once. Adding multiple header values would
always replace the content-language property in the response and the
entire header value.

This commit ensures that this behavior is supported.

Fixes gh-34488
2025-02-25 17:11:37 +01:00
Juergen Hoeller aff9ac72ec Avoid unnecessary CGLIB processing on configuration classes
Closes gh-34486
2025-02-25 16:20:12 +01:00
Brian Clozel f895d762cd Remove duplicate Content-Type header in error cases
Prior to this commit, the `DispatcherServlet` would try and reset the
response buffer in case of errors, if the response is not committed
already. This allows for more flexible error handling, even if the
response was being handled already when it errored.

Resetting the response buffer clears the body but leaves HTTP response
headers intact. This is done on purpose as to not clear headers
previously added by Servlet Filters. By leaving in place some headers
like "Content-Type", this does not take into account the fact that the
response body was cleared and that error handling will perform another
round of content negotiation. While this isn't a problem for some
Servlet containers which enforce a single "Content-Type" header value,
this can cause multiple/duplicate values for some others.

This commit ensures that the "Content-Type" response header is removed
at the same time as we clear the "producible media types" attribute:
another pass of content negotiation will be performed for error
handling.

Fixes gh-34366
2025-02-25 10:43:19 +01:00
Juergen Hoeller 634d1dd20b Consistent default ClassLoader fallback in hint classes
Closes gh-34470
2025-02-23 15:15:25 +01:00
Juergen Hoeller 725b02a66d Ignore entries cache if no matching root entry path found
Closes gh-34446
2025-02-23 14:02:57 +01:00
Brian Clozel 5a0bd9e5d4 Fix null value support in ContentCachingResponseWrapper
Prior to this commit, calling `setHeader` on the response wrapper would
have a separate code path for the "Content-Length" header. This did not
support calls with `null` values and would result in an exception.

This commit ensures that the cached content length value is reset in
this case and that the call is forwarded properly to the superclass.

Fixes gh-34460
2025-02-21 14:33:03 +01:00
Brian Clozel 6dd73ae3e4 Handle null values in MockHttpServletResponse#setHeader
Prior to this commit, `MockHttpServletResponse#setHeader` would not
remove the header entry when given a `null` value, as documented in the
Servlet API.
This commit ensures that this behavior is enforced.

Fixes gh-34464
2025-02-21 14:23:12 +01:00
Gang Cheng 4606337180 Prevent hung uploads in MultipartParser
This commit adds an onRequest() hook to request more data from
the source in order to avoid hung uploads in MultipartParser.

Closes gh-34388
Signed-off-by: Gang Cheng <chenggangpro@gmail.com>
2025-02-21 11:32:54 +01:00
Sébastien Deleuze f45a08d4f5 Remove BaseDefaultCodecs#synchronossMultipartPresent
Closes gh-34459
2025-02-20 09:07:26 +01:00
Sébastien Deleuze d62ce2969a Fix broken antora task
See https://github.com/spring-io/antora-extensions/pull/43

Closes gh-34454
2025-02-19 16:40:50 +01:00
Johnny Lim ed3fd12210 Add missing `@since` tags in MockHttpServletRequestDsl
This commit adds missing `@since` tags for formField() and formFields in
MockHttpServletRequestDsl. See gh-34412 related issue.

Closes gh-34448
Signed-off-by: Johnny Lim <izeye@naver.com>
2025-02-19 13:58:31 +01:00
Vincent Potucek 6f596e2e84 Add a project icon for IntelliJ IDEA
The icon comes from https://spring.io/img/projects/spring-framework.svg.

Closes gh-34444
Signed-off-by: Vincent Potucek <vincent.potucek@sap.com>
2025-02-19 13:45:16 +01:00
Juergen Hoeller 6786e1c3e5 Apply fallback in case of initial SmartClassLoader mismatch as well
See gh-34423
2025-02-18 20:40:13 +01:00
Juergen Hoeller 93134fd4d1 Apply fallback in case of any exception coming out of createClass
Closes gh-34423
2025-02-18 15:16:25 +01:00
Juergen Hoeller d0ceefedc6 Mark XML-configured executor/scheduler as infrastructure bean
Closes gh-34015
2025-02-18 13:13:34 +01:00
Juergen Hoeller e230ea537c Consistently resolve unique default candidate bean
Closes gh-34432
2025-02-18 13:11:36 +01:00
Juergen Hoeller 94eb6006e8 Leniently accept same singleton instance if implicitly appeared
Closes gh-34427
2025-02-18 13:01:08 +01:00
Sébastien Deleuze 2576702cda Use public interface for HTTP Interface documentation
Closes gh-34443
2025-02-18 11:57:04 +01:00