2350 Commits

Author SHA1 Message Date
Rossen Stoyanchev cecbe74cfc ContentCachingResponseWrapper skips contentLength for chunked responses
Closes gh-26182
2020-12-01 18:23:58 +00:00
Сергей Цыпанов 6d76951686 Remove unused package-private class o.s.w.u.p.SubSequence
(cherry picked from commit 42216b77df)
2020-11-26 15:48:19 +01:00
Rossen Stoyanchev 6327c60912 UrlPathHelper.removeJsessionid correctly appends remainder
Closes gh-26079
2020-11-16 11:30:07 +00:00
Rossen Stoyanchev 1c120f05eb Reinstate removal of jsessionid from lookup path
Closes gh-25864
2020-10-13 16:46:23 +01:00
Juergen Hoeller 94d330695f Avoid outdated Jackson API in tests
See gh-25907
2020-10-13 11:31:19 +02:00
Juergen Hoeller a29929db5b Polishing 2020-10-13 01:00:50 +02:00
Juergen Hoeller f24714f852 Polishing 2020-10-07 14:36:38 +02:00
Juergen Hoeller d1241e18de Polishing
(cherry picked from commit f010368a66)
2020-09-15 10:22:46 +02:00
Juergen Hoeller 4525d38ee8 Polishing 2020-09-14 23:31:22 +02:00
Rossen Stoyanchev ca6ac8e310 UriComponentsBuilder Javadoc update
Closes gh-25604
2020-09-08 11:59:13 +01:00
Rossen Stoyanchev aec3a4c69e Avoid unnecessary parsing of path params
Closes gh-25690
2020-09-08 11:54:32 +01:00
Rossen Stoyanchev 26141b0d56 Shared read-only instances of UrlPathHelper
UrlPathHelper is often created and used without customizations or with
the same customizations. This commit introduces re-usable, instances.
Effectively a backport of commit 23233c.

Closes gh-25690
2020-09-08 11:51:20 +01:00
Juergen Hoeller 9f2d8d4099 Explicit nullability declarations for getTarget() implementations 2020-09-01 23:33:27 +02:00
Juergen Hoeller f4973c9035 Polishing 2020-08-27 15:57:23 +02:00
Juergen Hoeller b883c0fc05 Polishing 2020-08-07 15:15:40 +02:00
Juergen Hoeller c0bd19aab5 Refine use of substring operations
Closes gh-25445
2020-08-07 15:13:45 +02:00
Juergen Hoeller 14b1d20822 Reset charset field in MockHttpServletResponse
Closes gh-25501
2020-08-07 15:03:41 +02:00
Juergen Hoeller c82f35aa1a Copy queryParams MultiValueMap through addAll (for independent List entries)
Closes gh-25423
2020-07-20 07:40:01 +02:00
Juergen Hoeller ac74de91f8 Polishing 2020-06-23 11:52:27 +02:00
Juergen Hoeller a045574418 Polishing 2020-06-10 11:19:52 +02:00
Juergen Hoeller 5587262fcd Polishing 2020-04-27 14:50:02 +02:00
Sam Brannen 6a6ad05aa7 Retain brackets for IPV6 address in MockHttpServletRequest
According to the Javadoc for ServletRequest's getServerName() method,
when the `Host` header is set, the server name is "the value of the
part before ':' in the Host header value ...". For a value representing
an IPV6 address such as `[::ffff:abcd:abcd]`, the enclosing square
brackets should therefore not be stripped from the enclosed IPV6
address.

However, the changes made in conjunction with gh-16704 introduced a
regression in Spring Framework 4.1 for the getServerName() method in
MockHttpServletRequest by stripping the enclosing brackets from the
IPV6 address in the `Host` header. Similarly, the changes made in
conjunction with gh-20686 introduced a regression in Spring Framework
4.3.13 and 5.0.2 in the getRequestURL() method in
MockHttpServletRequest by delegating to the getServerName() method
which strips the enclosing brackets.

This commit fixes the implementation of getServerName() so that the
enclosing brackets are no longer stripped from an IPV6 address in the
`Host` header. The implementation of getRequestURL() is therefore also
fixed.

In addition, in order to avoid a NullPointerException, the
implementations of getServerName() and getServerPort() now assert that
an IPV6 address present in the `Host` header correctly contains an
opening and closing bracket and throw an IllegalStateException if that
is not the case.

Closes gh-24916
2020-04-17 16:30:03 +02:00
Juergen Hoeller 4ec2844646 Honor overridden AcceptHeaderLocaleContextResolver.getDefaultLocale()
Closes gh-24871
2020-04-09 12:04:33 +02:00
Rossen Stoyanchev 11aaf6a90b UriComponentsBuilder.cloneBuilder copies uriVariables
Closes gh-24772
2020-03-26 16:42:23 +00:00
Juergen Hoeller 4d9d814b4f Mark MediaTypeNotSupportedStatusException as deprecated
Closes gh-24743
2020-03-24 01:06:08 +01:00
Juergen Hoeller 528fc662f0 Polishing 2020-03-13 23:49:03 +01:00
Juergen Hoeller 5eb8430688 Polishing 2020-02-12 18:14:08 +01:00
Rossen Stoyanchev dc561aee02 Update advice on RestTemplate
Closes gh-24503
2020-02-12 18:13:45 +01:00
Rossen Stoyanchev 0583b334b4 Escape quotes in filename
Also sync up to master and 5.1.x on refactorings in ContentDisposition
and ContentDispositionTests.

Closes gh-24230
2020-01-07 07:17:55 +00:00
Juergen Hoeller 14ecc0357e Polishing 2019-12-09 15:26:15 +01:00
Juergen Hoeller 7427884a91 Deprecate logger field in HandlerMethodArgumentResolverComposite 2019-07-31 23:26:56 +02:00
Juergen Hoeller 215caedd30 Polishing 2019-07-31 22:58:49 +02:00
Sam Brannen d893cdaabb Document that Ordered is not supported for @ControllerAdvice beans
Closes gh-23172
2019-06-21 12:48:20 +03:00
Juergen Hoeller 1d5a43f485 Polishing 2019-06-12 18:13:41 +02:00
Juergen Hoeller 7622d1e3fa Polishing 2019-06-12 14:34:48 +02:00
Juergen Hoeller d032beddb5 Thread-safe removal of destruction callbacks in web scopes
Closes gh-23117
2019-06-12 14:34:42 +02:00
Juergen Hoeller 53b53e21be Upgrade to Apache HttpClient 4.5.9 and Tomcat 8.5.42 2019-06-12 00:51:26 +02:00
Juergen Hoeller 8d5c36269e Polishing 2019-06-12 00:51:09 +02:00
Juergen Hoeller bb7096b024 Defensive concurrent access to shared file extension data structures
Closes gh-23064
2019-06-12 00:51:02 +02:00
Ilya Lukyanovich 5990548f6f Fix MockHttpServletRequest.setCookies to produce single cookie header
Prior to this commit, MockHttpServletRequest.setCookies() produced one
Cookie header per supplied cookie, resulting in multiple Cookie headers
which violates the specification.

This commit fixes this by ensuring that all cookie name-value pairs are
stored under a single Cookie header, separated by a semicolon.

Closes gh-23074
2019-06-06 17:26:09 +03:00
Juergen Hoeller c2b8c592ee Polishing 2019-05-21 00:08:40 +02:00
Juergen Hoeller a41a5e195f Polishing 2019-05-20 23:49:31 +02:00
Juergen Hoeller 3d437fd544 Upgrade to OkHttp 3.12.3 2019-05-08 17:05:00 +02:00
Juergen Hoeller c28cadbafc Polishing 2019-05-07 01:54:38 +02:00
Juergen Hoeller 9198e037c1 Consistent use of StringUtils.hasLength(String) vs isEmpty(Object) 2019-05-03 18:02:53 +02:00
Juergen Hoeller 901ced7b66 Polishing 2019-05-03 15:32:47 +02:00
Juergen Hoeller 0f0da73043 Polishing 2019-04-26 20:36:21 +02:00
Juergen Hoeller 486f64f748 Polishing 2019-04-08 20:07:33 +02:00
Juergen Hoeller 44f1d44e28 Polishing 2019-04-08 18:40:12 +02:00
Juergen Hoeller 2f8cdef058 Avoid expensive Stream API usage in HttpRange
See gh-22742
2019-04-08 18:39:55 +02:00