Commit Graph

17443 Commits

Author SHA1 Message Date
tamkylet a999c4aa7e readme writing changes to improve readability 2018-10-29 09:18:45 -04:00
Spring Buildmaster a82d726f76 Next Development Version 2018-10-29 10:33:23 +00:00
Brian Clozel 5fb8dec50e Upgrade to Reactor Californium-SR2 2018-10-29 10:31:29 +01:00
Juergen Hoeller dc1e3b4628 Exclude FactoryBean implementation methods on CGLIB proxies as well
Issue: SPR-17374
2018-10-27 14:36:56 +02:00
Rossen Stoyanchev fa096dc60f Minor refactoring in StringDecoder + polish
1. Avoid re-creating the List with delimited byte arrays on every
request if using the default delimiters which don't vary by charset.

2. Replace flatMap with flatMapIterable for splitOnDelimiter.

3. Avoid going through DataBufferUtils#join, and unnecessarily creating
Flux from the List, since the join method needs a list anyway.
2018-10-26 13:24:53 -04:00
Brian Clozel fc957e95bb Configure ResourceUrlProvider in WebFlux
Prior to this commit, no `ResourceUrlProvider` was configured
in WebFlux (no bean was contributed by the WebFlux infrastructure).
Also, several `ResourceTransformer` instances that extend the
`ResourceTransformerSupport` base class need a `ResourceUrlProvider`
to resolve absolute URLs when rewriting resource URLs. At this point,
no `ResourceUrlProvider` was configured and they could only resolve
relative URLs.

This commit contributes a new `ResourceUrlProvider` to the WebFlux
configuration; this bean can be reused by the WebFlux infrastructure and
application code.

This also automatically configure this shared `ResourceUrlProvider`
instance on the resource chain where needed.

Issue: SPR-17433
2018-10-26 13:56:00 +02:00
Juergen Hoeller 3fee8cb625 Polishing 2018-10-26 11:43:46 +02:00
Arjen Poutsma e68bf010da Fix memory leak for ServerSentEventHttpMessageWriter
Issue: SPR-17419
2018-10-26 11:36:05 +02:00
Juergen Hoeller f32e1bcbe3 Polishing 2018-10-26 11:07:29 +02:00
Vikash Tiwari 8df3fd3f1d Remove unnecessary null check 2018-10-26 10:17:04 +02:00
Rossen Stoyanchev 4faee165db Documentation updates for working with DataBuffers
Issue: SPR-17409
2018-10-25 23:46:39 -04:00
Rossen Stoyanchev 8223ed38c8 Polish Reactive Core and Codecs sections
Issue: SPR-17409
2018-10-25 23:45:09 -04:00
Juergen Hoeller 3681d58e98 SpringBeanContainer leniently applies fallback on any BeansException
Issue: SPR-17430
2018-10-25 18:06:06 +02:00
Brian Clozel 2146e13787 Fix absolute paths when transforming resources
Prior to this commit, `ResourceTransformerSupport.toAbsolutePath`
would call `StringUtils.applyRelativePath` in all cases. But this
implementation is prepending the given path even if the relative path
starts with `"/"`.

This commit skips the entire operation if the given path is absolute,
i.e. it starts with `"/"`.

Issue: SPR-17432
2018-10-25 16:42:47 +02:00
Juergen Hoeller a61d107606 Asciidoc revision (chapter declarations, javadoc references, etc) 2018-10-25 15:15:58 +02:00
Juergen Hoeller 67bd3f670f Upgrade to AspectJ 1.9.2, Rome 1.11.1, OpenPDF 1.2.5, POI 4.0 2018-10-25 15:15:47 +02:00
Arjen Poutsma 95542778ad Fix MultipartHttpMessageWriterTests
Issue: SPR-17419
2018-10-25 12:13:03 +02:00
Arjen Poutsma 7a8a2d9608 Fix HttpMessageWriter tests
Issue: SPR-17419
2018-10-25 12:13:03 +02:00
Arjen Poutsma 256a6fe6cb Fix memory leak for ServerSentEventHttpMessageWriter
This commit fixes a memory leak in ServerSentEventHttpMessageWriter
that occurs when the input stream contains an error. Test added as well.

Issue: SPR-17419
2018-10-25 12:13:03 +02:00
Brian Clozel d28b73ad22 Rollback to Asciidoctor 1.5.8 2018-10-25 10:12:01 +02:00
Juergen Hoeller 56a8526f3c Upgrade to Checkstyle 8.14 2018-10-25 00:29:08 +02:00
Juergen Hoeller fb2565f2fe Upgrade plugins to Kotlin 1.2.71 and Asciidoctor 1.5.9 2018-10-24 23:57:33 +02:00
Brian Clozel 50a4769162 Fix ResourceUrlEncodingFilter lifecycle
Prior to this commit, the `ResourceUrlEncodingFilter` would wrap the
response and keep a reference to the request. When
`HttpServletResponse.encodeURL` is later called during view rendering,
the filter looks at the request and extracts context mapping information
in order to resolve resource paths in views.

This approach is flawed, when the filter is used with JSPs - if the
request is forwarded to the container by the `InternalResourceView`,
the request information is overwritten by the container. When the view
is being rendered, the information available in the request is outdated
and does not allow to correctly compute that context mapping
information.

This commit ensures that that information is being extracted from the
request as soon as the `ResourceUrlProvider` is set as a request
attribute.

Issue: SPR-17421
2018-10-24 21:18:57 +02:00
Juergen Hoeller ffa032e78f Polishing 2018-10-24 20:46:26 +02:00
Juergen Hoeller f0f1979fc5 Support for @RequestParam Map declared with MultipartFile/Part values
Issue: SPR-17405
2018-10-24 20:44:58 +02:00
Arjen Poutsma 488a1d4561 Review DataBufferUtils for cancellation memory leaks
Issue: SPR-17408
2018-10-24 16:28:21 +02:00
Arjen Poutsma 611019b73c Fix memory leak for Jaxb2XmlEncoder
This commit fixes a memory leak in Jaxb2XmlEncoder that occurs when
the input stream contains an error. Test added as well.

Issue: SPR-17419
2018-10-24 16:28:21 +02:00
Arjen Poutsma 11a017d8b7 Add error stream tests for ProtobufEncoderTests
Issue: SPR-17419
2018-10-24 16:28:21 +02:00
Rossen Stoyanchev 2439f87a48 Add onDiscard hook to Jetty client request
The flatMap operation in writeAndFlushWith could buffer internally.

Issue: SPR-17424
2018-10-23 21:41:27 -04:00
Rossen Stoyanchev 2ba5ded306 Polish Jetty reactive HttpClient connector 2018-10-23 21:34:42 -04:00
Rossen Stoyanchev 2eae37dde0 Update ref docs on ResponseEntity and reactive types
Issue: SPR-17400
2018-10-23 16:42:31 -04:00
Rossen Stoyanchev 42b7c5a79b Upgrade to Californium snapshots
Towards Californium SR2 to confirm fix for SPR-17306.
2018-10-23 15:52:05 -04:00
Juergen Hoeller 1cb08f5782 Upgrade to RxJava 2.2.3 and Undertow 2.0.14 2018-10-23 19:34:39 +02:00
Rossen Stoyanchev feeec344e5 ForwardedHeaderFilter works with Servlet FORWARD
Issue: SPR-16983
2018-10-23 11:53:46 -04:00
Arjen Poutsma 51bb96db47 Fix ResourceRegionEncoder and tests
Fix ResourceRegionEncoder so that it checks for resource existance
before writing boundaries. Also defer data buffer allocation until
necessary.

Issue: SPR-17419
2018-10-23 16:41:48 +02:00
Arjen Poutsma eac9e66c46 Fix memory leak when canceling read from AsynchronousFileChannel
This commit fixes a memory leak that occurs when reading from a
AsynchronousFileChannel, and cancelling the subscription.

Issue: SPR-17419
2018-10-23 16:41:48 +02:00
Brian Clozel 28cf7b728f Relax handler supports checks in RequestMappingHandlerAdapter
Issue: SPR-17420
2018-10-22 20:31:41 +02:00
Juergen Hoeller f68b1e0bce Upgrade to Objenesis 3.0.1
Issue: SPR-17372
2018-10-22 18:54:18 +02:00
Juergen Hoeller c3c2383b0d Align serialVersionUID declaration with ASM master
Issue: SPR-17267
2018-10-22 18:53:23 +02:00
Rossen Stoyanchev 41e6aa6de2 Restore log level for resolved exceptions
The fix for SPR-17178 switched from debug to warn level warning for
all sub-classes of AbstractHandlerExceptionResolver where the request
concerned the DefaultHandlerExceptionResolver only.

This commit restores the original DEBUG level logging that was in
AbstractHandlerExceptionResolver from before SPR-17178. In addition
DefaultHandlerExceptionResolver registers a warnLogCategory by default
which enables warn logging and hence fulfilling the original goal
for SPR-17178.

Issue: SPR-17383
2018-10-22 12:13:18 -04:00
Rossen Stoyanchev de453ace86 Revert "@ExceptionHandler methods logs at DEBUG level again"
This reverts commit 162112.

Instead we'll go for a bigger rollback of the change from SPR-17178 so
that only DefaultHandlerExceptionResolver does warn logging by default.

Issue: SPR-17388
2018-10-22 11:46:02 -04:00
Arjen Poutsma 0176d362be Add error stream tests for Jackson2JsonDecoder
Issue: SPR-17418
2018-10-22 16:00:32 +02:00
Arjen Poutsma 946ec7e22e Fix memory leaks in ProtobufDecoder
Issue: SPR-17418
2018-10-22 16:00:32 +02:00
Arjen Poutsma a64e85fcc6 Javadoc 2018-10-22 16:00:32 +02:00
Arjen Poutsma 47fe05066d Add error stream tests for Jaxb2XmlDecoderTests
Issue: SPR-17418
2018-10-22 16:00:32 +02:00
Arjen Poutsma a37efc9881 Add error stream tests for XmlEventDecoder
Issue: SPR-17418
2018-10-22 16:00:32 +02:00
Arjen Poutsma f738273486 Fix buffering issue in StringDecoder
Issue: SPR-17418
2018-10-22 16:00:32 +02:00
Juergen Hoeller 1c67ef4bed ConfigurableWebApplicationContext needed for contextClass parameter
Issue: SPR-17414
2018-10-22 15:14:08 +02:00
Juergen Hoeller dd2ce20687 SpringFactoriesLoader tolerates whitespace around class names
Issue: SPR-17413
2018-10-22 15:13:58 +02:00
Juergen Hoeller 83a54dba7e Avoid stacktrace if root resource is not resolvable in file system
Issue: SPR-17417
2018-10-22 15:13:49 +02:00