Commit Graph

16632 Commits

Author SHA1 Message Date
Rossen Stoyanchev
5f96d7c46c Add notes on future deprecation of the RestTemplate
Issue: SPR-16993
2018-07-27 08:43:26 -04:00
Juergen Hoeller
cca8968a44 Polishing 2018-07-26 23:40:32 +02:00
Juergen Hoeller
b6a049a088 Polishing
(cherry picked from commit 7c9ba80f85)
2018-07-26 23:27:28 +02:00
Rossen Stoyanchev
2d83051ce1 bindToApplicatonContext uses WebSessionManager bean
Issue: SPR-17094
2018-07-26 16:05:33 -04:00
Rossen Stoyanchev
f9ff6d4192 Polish 2018-07-26 15:54:21 -04:00
Juergen Hoeller
514c28b7c0 Revise BeanFactory vs ApplicationContext section in reference docs
Issue: SPR-17095

(cherry picked from commit 8277ea5794)
2018-07-26 18:50:21 +02:00
Juergen Hoeller
5da58393c1 Polishing 2018-07-26 15:55:15 +02:00
Juergen Hoeller
79936d98de Properly identify event-related ClassCastExceptions on JDK 11
Issue: SPR-17093

(cherry picked from commit e458777925)
2018-07-26 15:07:10 +02:00
Spring Buildmaster
7dff7bb7a4 Next Development Version 2018-07-26 07:49:44 +00:00
Juergen Hoeller
d7cf2c869c MethodBeforeAdviceInterceptor implements BeforeAdvice marker interface
Includes related polishing in the advice interceptor implementations.

Issue: SPR-17088

(cherry picked from commit 4e03d3fdcb)
2018-07-25 20:16:48 +02:00
Juergen Hoeller
c89fb745f7 ListBasedXMLEventReader uses defensive modifiable copy of given List
(cherry picked from commit 9ab63b8494)
2018-07-25 19:06:55 +02:00
Juergen Hoeller
e214ee5c85 Backport of WebMvcConfigurationSupport javadoc revision 2018-07-25 15:39:39 +02:00
Juergen Hoeller
93ef169c5c Polishing 2018-07-25 14:40:31 +02:00
Brian Clozel
407bd96cf3 ResponseEntityResultHandler overwrites headers
Prior to this commit, controller handlers (regular and exception
handlers as well) would not overwrite existing HTTP response headers on
the exchange. This would lead to situations where Content-Type values
set during the initial handling phase would not be overwritten when
handling an error later on.

This commit aligns the implementation of that result handler on the
Spring MVC one in that regard.

Issue: SPR-17082
(Cherry-picked from 195f3f07e7)
2018-07-24 22:23:52 +02:00
Juergen Hoeller
0b5c099de2 Polishing 2018-07-24 22:10:07 +02:00
Juergen Hoeller
4f9a18f5aa Order setter for DefaultSimpUserRegistry
Issue: SPR-17023
2018-07-24 18:56:52 +02:00
Rossen Stoyanchev
9b3d80c5e4 Update STOMP section on working with subscriptions
1. Revise @SubscribeMapping to address common points of confusion.
2. Add ExecutorSubsribableChannel.
3. Split Events and Interception in two.

Issue: SPR-16950
2018-07-24 12:25:41 -04:00
Rossen Stoyanchev
dc066b0530 "Order of messages" in STOMP section of reference docs
Issue: SPR-13989
2018-07-24 12:23:39 -04:00
Juergen Hoeller
0c44b5224f Polishing
(cherry picked from commit dd4468a)
2018-07-24 16:34:56 +02:00
Juergen Hoeller
207e8c2409 BeanFactoryAdvisorRetrievalHelper avoids synchronization for name cache
Issue: SPR-16570

(cherry picked from commit 7f1a8d7)
2018-07-24 16:34:50 +02:00
Juergen Hoeller
2329588856 Upgrade to Mockito 2.19.1 2018-07-24 15:00:47 +02:00
Juergen Hoeller
f677d684e7 Polishing 2018-07-24 15:00:35 +02:00
Juergen Hoeller
3878db2e8c Provide predetermined capacity for cache operation collections
Issue: SPR-17079

(cherry picked from commit 20c34cb)
2018-07-24 14:59:05 +02:00
Rossen Stoyanchev
24a113fb27 Ensure headers work with ResponseEntity + reactive body
Issue: SPR-17076
2018-07-24 00:26:01 -04:00
Juergen Hoeller
e21db2619b AspectJExpressionPointcut leniently ignores non-composable interfaces
Issue: SPR-17003

(cherry picked from commit bccff73)
2018-07-22 22:35:32 +02:00
Juergen Hoeller
f5dd4d2c02 Polishing 2018-07-22 19:33:40 +02:00
Juergen Hoeller
192113de60 Correctly determine and propagate validation hints to DataBinder
Issue: SPR-17073

(cherry picked from commit 3c65c17)
2018-07-21 12:34:55 +02:00
Brian Clozel
f89511e7fe Switch order of multipart Content-Type directives
Since SPR-15205, the `FormHttpMessageConverter` is adding a `charset`
directive to the `Content-Type` request header in order to help servers
understand which charset is being used to encode headers of each part.

As reported in SPR-17030 and others, some servers are not parsing
properly such header values and assume that `boundary` is the last
directive in the `Content-Type` header.

This commit reorders the charset information right before the boundary
declaration to get around those issues.

Issue: SPR-17030
(Cherry-picked from 390bb871d8)
2018-07-20 18:16:53 +02:00
Juergen Hoeller
c3f6403f61 Polishing 2018-07-20 16:45:17 +02:00
Rossen Stoyanchev
5007d01c17 Fix for encoding issue with MvcUriComponentsBuilder
Provide method for stronger encoding of expanded URI variables when
building links from views.

Issue: SPR-17027
2018-07-19 19:07:22 -04:00
Rossen Stoyanchev
f1c55a3b4a UriComponentsBuilder method to configure URI variables
See Javadoc on UriComponentsBuilder#uriVariables for details.

This helps to prepare for SPR-17027 where the MvcUriComponentsBuilder
already does a partial expand but was forced to build UriComonents
and then create a new UriComponentsBuilder from it to continue. This
change makes it possible to stay with the same builder instance.

Issue: SPR-17027
2018-07-19 19:07:22 -04:00
Rossen Stoyanchev
34a0cdfc33 Minor fixes: UriComponentsBuilder, UriComponents, docs
After the latest changes, two small fixes in the clone method to copy
the encode flag, and in the encodeUriTemplate method to account for
possible null query params.

Improvements in the URI encoding section.

Issue: SPR-17039, SPR-17027
2018-07-19 19:07:22 -04:00
Juergen Hoeller
1cd0135195 Restore original DefaultAdvisorChainFactory MethodMatcher invocation
Includes test for @Async pointcut against AOP proxy without target.
2018-07-20 00:33:27 +02:00
Juergen Hoeller
0c5c3103c6 ReflectiveMethodExecutor skips interface search (plus related polishing) 2018-07-19 16:51:13 +02:00
Juergen Hoeller
c66f9d8880 Javadoc update: ConfigurationClassPostProcessor is priority-ordered
Issue: SPR-17062

(cherry picked from commit 0b60447)
2018-07-19 13:24:48 +02:00
Juergen Hoeller
4d3a899a53 OrderUtils caches order values (for AnnotationAwareOrderComparator)
Issue: SPR-17064

(cherry picked from commit d0bbbf4)
2018-07-19 13:24:43 +02:00
Juergen Hoeller
11fc086309 Prefer ArrayList/ArrayDeque over LinkedList for multi-element holders
LinkedList remains in place where a List is likely to remain empty or single-element (in order to avoid unused capacity).

Issue: SPR-17037

(cherry picked from commit 9c08a48)
2018-07-19 00:08:13 +02:00
Juergen Hoeller
ed54895e53 Consistent exposure of nested parameter type in binding exceptions 2018-07-18 19:56:06 +02:00
Juergen Hoeller
b72594d799 Find annotations on implemented generic interface methods as well
Issue: SPR-16060

(cherry picked from commit 23d4862)
2018-07-18 19:56:00 +02:00
Juergen Hoeller
4341838a21 Polishing 2018-07-18 14:53:19 +02:00
Brian Clozel
58f58e404e Avoid null signals when resolving handler arguments
Prior to this commit, resolving an argument for a WebFlux controller
that's missing from the request and not required by the handler would
throw a NullPointerException in some cases.

This involves the conversion of the parameter (a `String` parameter type
might not trigger this behavior) and sending a `null` within a reactive
stream, which is illegal per the RS spec.

We now rely on a `Mono.justOrEmpty()` to handle those specific cases.

Issue: SPR-17050
(Cherry-picked from a7f97a1669)
2018-07-18 14:48:06 +02:00
Juergen Hoeller
c0040a5508 Polishing 2018-07-18 14:03:54 +02:00
Juergen Hoeller
55563c16b5 StringUtils.parseLocaleString detects variant without country
The parseLocale method also turns an empty locale into null now, compatible with parseLocaleString behavior.

Includes tests for parsing all available locales on the JVM, checking toString/toLanguageTag equality between parsed and original locale.

Issue: SPR-7598
Issue: SPR-16651

(cherry picked from commit cab35aa)
2018-07-18 14:03:30 +02:00
Juergen Hoeller
ae1d500bc3 UrlBasedViewResolver exposes redirect prefix as bean name
Issue: SPR-17045

(cherry picked from commit b8d2a16)
2018-07-18 13:59:32 +02:00
Juergen Hoeller
9134588a82 Never return null from AnnotationMetadata.getMetaAnnotationTypes
Issue: SPR-17046

(cherry picked from commit cacd14c)
2018-07-18 13:59:11 +02:00
Juergen Hoeller
d283424c82 Update ref doc references to Number/Currency/PercentStyleFormatter
Issue: SPR-17022

(cherry picked from commit 39d4550)
2018-07-18 13:58:45 +02:00
Andrew McCallum
6e019f9ed0 Correct method signature in code example
Closes gh-1887
2018-07-18 09:08:29 +02:00
Rossen Stoyanchev
d9d41b4398 Polish 2018-07-17 17:41:44 -04:00
Rossen Stoyanchev
eac0ddce13 Update URI Encoding section 2018-07-17 15:58:47 -04:00
Rossen Stoyanchev
a363a229eb Update URI links section after encoding changes
Issue: SPR-17039
2018-07-16 21:25:27 -04:00