Commit Graph

22536 Commits

Author SHA1 Message Date
Christoph Dreis 360f555e77 Introduce ResponseEntity.internalServerError()
Closes gh-26952
2021-05-18 16:57:20 +02:00
Sam Brannen 7c756027a0 Deprecate internal APIs in ScriptUtils in spring-jdbc
Many of the utility methods in ScriptUtils are public only because they
were once invoked from JdbdTestUtils in spring-test, which is no longer
the case. Consequently, there should no longer be a need for any
external clients to invoke such methods.

To address this, this commit formally deprecates the following methods
in ScriptUtils in spring-jdbc.

- readScript(...)
- containsSqlScriptDelimiters(...)
- splitSqlScript(...)

Closes gh-26947
2021-05-18 15:43:54 +02:00
Sam Brannen 4c642ccdcd Logically reorganize methods in ScriptUtils
See gh-26947
2021-05-18 14:56:49 +02:00
Sam Brannen fab7b1cebe Polish ScriptUtils internals in spring-r2dbc
See gh-26947
2021-05-18 14:29:18 +02:00
Rossen Stoyanchev 101ed17b6f Polishing contribution
Closes gh-26927
2021-05-17 17:28:16 +01:00
Ruslan Akhundov 66588bae92 CorsConfiguration supports port pattern and port lists
See gh-26927
2021-05-17 17:28:16 +01:00
Sam Brannen d33545bdce Avoid duplicate comment processing in ScriptUtils in spring-r2dbc
See gh-26947
2021-05-17 13:15:44 +02:00
Sam Brannen e8e157ebf8 Polish ScriptUtils in spring-r2dbc 2021-05-17 12:49:46 +02:00
Sam Brannen 7f5904c68b Remove internal APIs from ScriptUtils in spring-r2dbc
Prior to this commit, many of the utility methods in ScriptUtils in
spring-r2dbc were public by accident: they were copied from ScriptUtils
in spring-jdbc without changing the visibility when spring-r2dbc was
introduced in Spring Framework. 5.3 GA.

This commit corrects this mistake by removing internal APIs from
ScriptUtils in spring-r2dbc from the public contract.

See gh-26947
2021-05-17 12:15:30 +02:00
Sam Brannen 66e488850b Ignore comments when searching for statement delimiter in ScriptUtils
This commit picks up where 569ce840cf left off, by correctly invoking
the new containsStatementSeparator(...) method from
executeSqlScript(...) in ScriptUtils in spring-r2dbc.

See gh-26911
2021-05-17 12:07:04 +02:00
Sébastien Deleuze 3dba3691a7 Upgrade to Coroutines 1.5.0
This commit upgrades to Coroutines 1.5.0 while retaining
Coroutines 1.4.x compatibility.

Closes gh-26897
2021-05-17 11:37:02 +02:00
Sam Brannen c80c4e001a Add missing author tags and sync SQL script support for JDBC & R2DBC 2021-05-16 17:18:56 +02:00
Sam Brannen 8da049b613 Update Javadoc URL for Apache HttpComponents Client 2021-05-16 15:22:37 +02:00
Sam Brannen 1acd832759 Fix link in @EventListener's `id` Javadoc 2021-05-16 15:08:33 +02:00
Sam Brannen 261927b72a Stop using deprecated Netty feature in ReactorHttpsServer 2021-05-16 15:03:42 +02:00
Sam Brannen 24aa7f546b Upgrade to JUnit 5.7.2
Closes gh-26946
2021-05-16 15:00:45 +02:00
Sam Brannen 4cfad25468 Polish ScriptUtils implementations 2021-05-14 15:15:12 +02:00
Sam Brannen 569ce840cf Ignore comments when searching for statement delimiter in ScriptUtils
Prior to this commit, the implementations of
ScriptUtils.containsSqlScriptDelimiters() in spring-jdbc and
spring-r2dbc did not ignore comments when searching for the statement
delimiter within an SQL script. This resulted in subtle bugs if a
comment contained a single single-quote or single double-quote, since
the absence of the closing single-quote or double-quote led the
algorithm to believe that it was still "within a text literal". Similar
issues could arise if a comment contained the sought statement
delimiter but the rest of the script did not contain the sought
statement delimiter. In such cases, the algorithms in ScriptUtils could
erroneously choose an incorrect statement delimiter -- for example,
using the fallback statement delimiter instead of the delimiter
specified by the user.

This commit avoids such bugs by ignoring single-line comments and block
comments when searching for the statement delimiter within an SQL
script.

Closes gh-26911
2021-05-14 14:23:27 +02:00
Sam Brannen fae484855b Fix grammar in inline comment in HttpStatus
See gh-26842
2021-05-13 16:21:45 +02:00
Qimiao Chen cab20d1202
Fix punctuation in Custom Cache Resolution section of ref docs
Closes gh-26938
2021-05-13 15:30:58 +02:00
Sam Brannen e2bf513563 Remove accidental dependency on Spring 5.2.x in spring-r2dbc tests 2021-05-12 13:43:36 +02:00
Sam Brannen 84e56bb5d9 Sync ScriptUtilsUnitTests implementations to simplify maintenance 2021-05-12 12:54:35 +02:00
Sam Brannen 6f5e66f00c Add missing tests for multiple comment prefixes in R2DBC ScriptUtils
See gh-23289
2021-05-12 12:23:54 +02:00
Sam Brannen cda72e4a70 Ignore delimiter enclosed in double quotes in ScriptUtils
Prior to this commit, the containsSqlScriptDelimiters() method in
ScriptUtils ignored delimiters enclosed in single quotes but not those
enclosed within double quotes, which contradicts the algorithm in
splitSqlScript() and therefore constitutes a bug.

This commit fixes this bug in the ScriptUtils implementations in
spring-jdbc and spring-r2dbc.

Closes gh-26935
2021-05-12 12:07:55 +02:00
Sam Brannen e31a4c4c77 Polishing 2021-05-12 11:31:15 +02:00
Spring Buildmaster 4809632f44 Next development version (v5.3.8-SNAPSHOT) 2021-05-12 05:50:28 +00:00
Arjen Poutsma 0d0d75e253 Ensure DefaultPartHttpMessageReader temp directories do not collide
This commit makes sure that the DefaultPartHttpMessageReader uses a
random temporary directory to store uploaded files, so that two
instances do not collide.

See gh-26931
2021-05-11 21:12:50 +02:00
Arjen Poutsma cce60c479c Ensure Synchronoss temp directories do not collide
This commit makes sure that Synchronoss uses a random temporary
directory to store uploaded files, so that two instances do not collide.

Closes gh-26931
2021-05-11 21:12:50 +02:00
Juergen Hoeller 1469bdbc70 Nullability refinements and related polishing 2021-05-11 16:50:19 +02:00
Juergen Hoeller be52ec8bd5 DataClassRowMapper exposes generic constructor parameters for type conversion
Closes gh-26881
2021-05-11 16:49:25 +02:00
Sam Brannen cd9cad31f9 Increase the likelihood that timed tests pass on CI server 2021-05-11 16:16:18 +02:00
Juergen Hoeller 60c551a95b Correct clientInboundChannel assertion (includes constructor javadoc)
Closes gh-26896
2021-05-11 15:49:38 +02:00
Juergen Hoeller 4164fc63b1 CandidateComponentsIndexer introspects any kind of class (including records)
Closes gh-26909
2021-05-11 15:49:15 +02:00
Juergen Hoeller 0865abef83 Expose current cached session count
Closes gh-26811
2021-05-11 15:47:15 +02:00
Juergen Hoeller 90af2d5794 Log delegate service initialization at debug level (instead of info)
Closes gh-26810
2021-05-11 15:46:41 +02:00
Juergen Hoeller 5f5cd8a7c4 Log resource path resolution failure at debug level (instead of warn)
Closes gh-26828
2021-05-11 15:46:21 +02:00
Juergen Hoeller 46b7cd54a1 Log missing web application context at warn level (instead of debug)
Closes gh-26925
2021-05-11 15:45:36 +02:00
Juergen Hoeller 7f670bbe68 TransactionSynchronization does not support @Order (just Ordered interface)
See gh-21725
2021-05-11 15:45:05 +02:00
Stephane Nicoll 6aaf7596c0 Upgrade to Reactor 2020.0.7
Closes gh-26890
2021-05-11 15:34:41 +02:00
Juergen Hoeller 4f2c589fe6 Upgrade to Jackson 2.12.3, Jetty 9.4.40, Hibernate ORM 5.4.31, Groovy 3.0.8, Caffeine 2.9.1, Woodstox 6.2.6, Protobuf 3.15.8, XStream 1.4.16, OpenPDF 1.3.26, Checkstyle 8.42, Mockito 3.9, HtmlUnit 2.49.1 2021-05-11 00:19:43 +02:00
Rossen Stoyanchev aa51ed1940 Fix failing tests
This commit ensures that if an Origin is returned as it was provided,
possibly with a trailing slash.

See gh-26892
2021-05-10 14:15:16 +01:00
Rossen Stoyanchev dc4e053d59 CorsConfiguration ignores trailing "/" in pattern
Recent commit dddcc5e9ad ensured a
trailing "/" in the Origin header has no effect. This commit does the
same for a trailing "/" in configured patterns.

See gh-26892
2021-05-10 13:30:02 +01:00
ShindongLee 07ba95739b Fix parameter bug of handler inside the filterFunction DSL
Co-authored-by: hojongs <hojong.jjh@gmail.com>
Co-authored-by: bjh970913 <bjh970913@gmail.com>

Closes gh-26838
2021-05-10 09:35:56 +02:00
Rossen Stoyanchev 0468ef46ac Follow-up fix for recent change to PORT_PATTERN
The pattern was changed in 65797d04f2
to check for characters up until "/", instead of for digits, but now
also checks up until "?" and "#".

Closes gh-26905
2021-05-10 07:19:17 +01:00
Rossen Stoyanchev eb03144e9d RSocketRequester implements Disposable
Closes gh-26886
2021-05-10 07:19:17 +01:00
Rossen Stoyanchev 29790d5bb1 Update docs on how a `@ModelAttribute` is sourced
Closes gh-26873
2021-05-10 07:19:17 +01:00
Sam Brannen 355d394d7f Polish contribution
See gh-25200
2021-05-08 19:40:13 +02:00
Vlad Kisel 9ddab9e69b Support single-value request param resolution for data class constructors
Prior to this commit, when Web MVC attempted to resolve a constructor
argument for a data class constructor with @ModelAttribute binding,
ModelAttributeMethodProcessor failed to unwrap the array returned by
WebRequest.getParameter(String).

According to the Javadoc for WebRequest.getParameter(String), "a
single-value parameter will be exposed as an array with a single
element."

This commit fixes this issue by extracting the single value from such
an array and using that as the constructor argument (potentially
converted by the WebDataBinder).

Closes gh-25200
2021-05-08 19:25:54 +02:00
Sam Brannen c20a43f72b Polish WebRequestDataBinderIntegrationTests 2021-05-08 18:12:55 +02:00
Rossen Stoyanchev e0fa58aa0f Polishing contribution
Closes gh-26905
2021-05-07 17:30:40 +01:00