Commit Graph

14654 Commits

Author SHA1 Message Date
Rossen Stoyanchev
fc7bededd0 Support data binding for multipart requests in WebFlux
Issue: SPR-14546
2017-05-03 22:36:04 -04:00
Rossen Stoyanchev
b5089ac092 Support @RequestBody Flux<Part> in WebFlux
This commit turns the Synchronoss NIO Multipart HttpMessageReader into
a reader of Flux<Part> and creates a separate reader that aggregates
the parts into a MultiValueMap<String, Part>.

Issue: SPR-14546
2017-05-03 18:46:41 -04:00
Juergen Hoeller
d43dfc7bae Properly extract jar file from Tomcat war URL
Issue: SPR-15485
2017-05-03 21:58:59 +02:00
Juergen Hoeller
4d86515fa5 Overridable Commons Logging bridge in separate spring-jcl jar
Issue: SPR-14512
2017-05-03 20:29:05 +02:00
Arjen Poutsma
cf7dfc7b17 Properly close channel in SynchronossPart
This commit properly closes the opened channels in the SynchronossPart,
and also makes sure that the entire contents is copied, not just the
first batch.
2017-05-03 14:51:22 +02:00
Juergen Hoeller
27057889f8 Polishing 2017-05-03 13:45:29 +02:00
Juergen Hoeller
d74542ed21 Honor @Autowired(required=false) at parameter level
Includes a revision of the AutowireCandidateResolver SPI with default methods.

Issue: SPR-15268
2017-05-03 13:42:16 +02:00
Phillip Webb
07ef7a97c7 Cache SpringFactoriesLoader loads
Update `SpringFactoriesLoader` to cache property file loads. This helps
reduce the number of garbage objects created as each load uses an 8K
char buffer.

Issue: SPR-15509
2017-05-03 12:51:52 +02:00
Arjen Poutsma
ed4bd43cac Add writableChannel to WritableResource
This commit introduces a `writableChannel()` method to
`WritableResource`, defaulting to `Channels.newChannel`, but with
overrides for file-based resources.
2017-05-03 11:44:01 +02:00
Juergen Hoeller
9d8e9cf243 Common root cause introspection algorithm in NestedExceptionUtils
Issue: SPR-15510
2017-05-03 11:31:28 +02:00
Rossen Stoyanchev
16901b1497 Add bindToHttpHandler to WebTestClient
Issue: SPR-15499
2017-05-02 18:13:27 -04:00
Rossen Stoyanchev
4db1eb1e4e Polish 2017-05-02 17:59:22 -04:00
Rossen Stoyanchev
44786ff840 Merge pull request #1413 from gvdenbro/forwarded-header-server-port-fix 2017-05-02 16:59:02 -04:00
Rossen Stoyanchev
056284b407 Polish 2017-05-02 16:58:19 -04:00
Gregory Vandenbroucke
ec55e429f0 Full "Forwarded" header support including port number
Issue: SPR-15504
2017-05-02 16:47:32 -04:00
Rossen Stoyanchev
2ccf78743a Move 500 error handling to HttpWebHandlerAdapter
Issue: SPR-15506
2017-05-02 16:44:37 -04:00
Rossen Stoyanchev
1881727b37 Remove ServerWebExchange#getRequestParams
Issue: SPR-15508
2017-05-02 16:09:55 -04:00
Juergen Hoeller
7f19e57d9d Polishing 2017-05-02 21:38:09 +02:00
Juergen Hoeller
b709c77329 Multipart file tests reliably pass on Windows as well
Issue: SPR-14546
2017-05-02 21:26:31 +02:00
Juergen Hoeller
817e80c56b Property actually throws exception for no write method found
Issue: SPR-15507
2017-05-02 21:16:31 +02:00
Juergen Hoeller
7ca0094fa1 ResolvableType.clearCache() clears SerializableTypeWrapper cache as well
Issue: SPR-15503
2017-05-02 21:13:55 +02:00
Stephane Nicoll
3b8b3502a8 Update copyright header 2017-05-02 16:39:28 +02:00
Phillip Webb
90477b40a4 Defer Charset.availableCharsets() call
Change the `StringHttpMessageConverter` to defer calling
Charset.availableCharsets() until absolutely necessary to help improve
startup times.

Issue: SPR-15502
2017-05-02 16:39:04 +02:00
Rossen Stoyanchev
2390748fd7 WebFlux multpart support polish + minor refactoring 2017-05-01 18:00:08 -04:00
Arjen Poutsma
ea85431ac5 Add error filter to WebClient integration test
This commit adds a `WebClient` integration test that shows how to use
`ExchangeFilterFunction`s for error handling purposes.

Issue: SPR-15403
2017-05-01 13:36:35 +02:00
Juergen Hoeller
057e388b6b Streamlined JAF dependencies (plus upgrade to Netty 4.1.10)
Issue: SPR-14908
2017-05-01 13:34:31 +02:00
Juergen Hoeller
12a95d8c68 Upgrade to RxJava 2.1
Issue: SPR-15497
2017-04-30 12:53:37 +02:00
Rossen Stoyanchev
c7338c70dc Support async wrappers for Principal and WebSession
Issue: SPR-15494
2017-04-28 16:03:41 -04:00
Rossen Stoyanchev
1292bb20f9 WebTestClient supports customer argument resolvers
Issue: SPR-15495
2017-04-28 15:04:43 -04:00
Sebastien Deleuze
f2caaa9195 Add @Request(Param/Part) support for multipart requests
Issue: SPR-14546
2017-04-28 17:02:46 +02:00
Sebastien Deleuze
4bfd04b3c5 Add multipart support to ServerWebExchange
Issue: SPR-14546
2017-04-28 16:42:23 +02:00
Sebastien Deleuze
8e272bc5b0 Expose ServerCodecConfigurer as a bean
With this commit, ServerCodecConfigurer is now exposed as a bean in
order to be provided to DefaultServerWebExchange via
WebHttpHandlerBuilder and HttpWebHandlerAdapter. This allows
DefaultServerWebExchange to get configured codecs for reading form or
multipart requests.

Issue: SPR-14546
2017-04-28 16:42:23 +02:00
Sebastien Deleuze
a712c19661 Add multipart support to WebFlux functional API
Issue: SPR-14546
2017-04-28 16:42:23 +02:00
Sebastien Deleuze
852dc84d38 Add MultipartHttpMessageWriter
This commit adds a reactive HttpMessageWriter that allows
to write multipart HTML forms with multipart/form-data
media type.

Issue: SPR-14546
2017-04-28 16:42:23 +02:00
Sebastien Deleuze
23e4dd6d3d Add reading reactive multipart request support
This commit introduces reactive multipart support by adding a new
MultipartHttpMessageReader interface (with default methods) and a
SynchronossMultipartHttpMessageReader implementation based on
the Synchronoss NIO Multipart implementation
(https://github.com/synchronoss/nio-multipart).

Issue: SPR-14546
2017-04-28 16:42:23 +02:00
Juergen Hoeller
7f1fa225fe Latest dependency updates (Groovy 2.4.11, RxJava 1.2.10, H2 1.4.195) 2017-04-28 12:06:55 +02:00
Stephane Nicoll
0f6704202d Merge pull request #1404 from jonathanborenstein:master
* pr/1404:
  Polish "Use Java 8 forEach method on Map"
  Use Java 8 forEach method on Map
2017-04-28 11:07:40 +02:00
Stephane Nicoll
1b9e12f52f Polish "Use Java 8 forEach method on Map"
Closes gh-1404
2017-04-28 11:07:08 +02:00
Jon Borenstein
13dc0cd828 Use Java 8 forEach method on Map 2017-04-28 11:07:08 +02:00
Juergen Hoeller
1ea54eb2c6 GenericFilterBean lazily initializes its default environment
Alignment with HttpServletBean; consistent use of EnvironmentCapable.

Issue: SPR-15469
2017-04-27 21:38:30 +02:00
Juergen Hoeller
04f0f137e6 Aligned exception message for httpOnly
Issue: SPR-15488
2017-04-27 21:32:11 +02:00
Juergen Hoeller
baa7b1c6c8 Simplified match condition checks
Issue: SPR-15477
2017-04-27 21:31:50 +02:00
Juergen Hoeller
17f274fd6a Debug log messages for value retrieval exceptions
Issue: SPR-15481
2017-04-27 21:31:39 +02:00
Andy Clement
c1edb3b5bd Enforce limit on classes loaded by Spel compiled expression loader
Until this change a single classloader was used to load
all compiled SpEL expressions. This meant in a context where an
expression was repeatedly flipping between compiled and interpreted
mode (which can happen if in MIXED mode compilation and changing
the context around the evaluation) the classloader would continually
load a new compiled version but not orphan the old compiled version.
This eventually uses up all the memory as the number of classes
is ever increasing.

With this change classloaders are used to load 100 compiled
expressions. The 101st will be loaded by a new one. Orphaning the
old classloader means if an expression is ever recompiled there
is more likely to be no anchored references left to the older
compiled form and it can be GC'd. In the MIXED situation above it
should help alleviate the problem of older classes never being
candidates for GC.

Issue: SPR-15460
2017-04-27 11:31:56 -07:00
Juergen Hoeller
cd95f34666 Merge pull request #1399 from dreis2211/SPR-15477
Optimize AntPathMatcher when checking for potential matches
2017-04-27 20:26:37 +02:00
Christoph Dreis
13b39521d8 Optimize AntPathMatcher when checking for potential matches
Issue: SPR-15477
2017-04-27 19:04:36 +02:00
Juergen Hoeller
d9bde0812f Merge pull request #1373 from lc-nyovchev/master
HttpOnly Cookie Result Matcher
2017-04-27 15:20:07 +02:00
nyo
e80de55929 Added httpOnly cookie ResultMatcher 2017-04-27 14:22:00 +02:00
Stephane Nicoll
547c4f69a4 Add getTargetDataSource to TransactionAwareCacheDecorator
Issue: SPR-15479
2017-04-27 11:34:10 +02:00
Stephane Nicoll
333e5c6b01 Polish 2017-04-27 11:29:14 +02:00