Commit Graph

16442 Commits

Author SHA1 Message Date
Rossen Stoyanchev 417bb302c3 ReactorNettyWebSocketSession implements close properly
Issue: SPR-16774
2018-05-01 12:05:20 -04:00
Rossen Stoyanchev b0aa08a671 Consistent handling of URISyntaxException
Issue: SPR-16778
2018-04-30 21:05:08 -04:00
Sebastien Deleuze 9dc79982e2 Upgrade to Kotlin 1.2.41
Fixes KT-23973 critical regression
2018-04-30 10:48:23 +02:00
Stephane Nicoll 43f2334e82 Keep YAML entries that haven an empty array value
Prior to this commit, a YAML entry that define an empty array value was
lost. This commit makes sure to flag it with an empty String, which
corresponds as an empty comma separated list of entries in the
properties format.

Issue: SPR-16769
2018-04-29 11:15:53 +02:00
Nickloas 6c6e44b58e Fix typo
Closes gh-1813
2018-04-28 10:52:03 +02:00
Johnny Lim c6b60f0c00 Polish 2018-04-27 14:09:35 -04:00
sdeleuze 7aba6ca9d6 Fine tune WebFlux server logging verbosity
With this commit, WebFlux server uses warning instead of error log level
for request handling, and also just print the message instead of the
stacktrace which is mostly meaningless in reactive world.

Complementary to this change, Reactor Netty removed additional logging
as part of https://github.com/reactor/reactor-netty/issues/339.

Issue: SPR-16688
2018-04-27 10:36:06 +02:00
nkjackzhang dca77c0666 Fix broken anchor link in WebFlux refdoc 2018-04-27 08:49:51 +02:00
sdeleuze df6e690e33 Reuse PartBodyStreamStorageFactory in SynchronossPartGenerator
Issue: SPR-16727
2018-04-26 11:01:17 +02:00
nkjackzhang a702ef8074 Fix typos in Spring MVC refdoc
1. Consistent with "xml code" examples.
2. "xml()" is a static method and will use default builder config,
   so use createXmlMapper(true) instead.
3. Fix mvc namespace tag typo.
2018-04-26 10:03:27 +02:00
Rossen Stoyanchev f7376bdde3 Better assertion message in MockPart
Issue: SPR-16767
2018-04-25 10:00:18 -04:00
nkjackzhang f9e31b503c Fix typos
Closes gh-1806
2018-04-25 10:07:34 +02:00
hasheniuk 3551dd92fb Fix typo
Closes gh-1804
2018-04-24 10:06:49 +02:00
Rossen Stoyanchev c23297fe76 Add more detail to ISE in ServerEndpointExporter
Issue: SPR-16655
2018-04-23 17:04:16 -04:00
Rossen Stoyanchev a5622d0dd2 Validate contextPath in RedirectView
Issue: SPR-16752
2018-04-23 15:21:33 -04:00
Brian Clozel 72cfe41f30 Disable HTTP Range support for InputStreamResource
Prior to this commit, the `AbstractMessageConverterMethodProcessor`
would fail to convert `InputStreamResource` to `ResourceRegion` as
expected, since the content length cannot be read without consuming the
stream. This is enforced by the `HttpRange` class.

Now the method processor would still try to output HTTP range response
headers to provide range support information. This step is using the
resource content length and reads the input stream, leading to
exceptions such as "IllegalStateException: InputStream has already been
read".

This commit improves the return type detection and excludes early
`InputStreamResource` return types. With those types, HTTP range support
is now completely disabled.

Issue: SPR-16754
(cherry picked from commit e9a8a5065b)
2018-04-23 18:40:15 +02:00
sdeleuze 4ff595e2bc Upgrade Kotlin to 1.2.40 2018-04-23 15:31:31 +02:00
sdeleuze 2c766b9501 Enable KotlinScriptTemplateTests after KT-18833 fix 2018-04-23 15:31:31 +02:00
Dimitrios (Dimi) Liapis 2960a558d7 Fix typo
See gh-1803
2018-04-21 18:21:19 +02:00
Brian Clozel d69a281e5c Upgrade to Netty 4.1.24.Final 2018-04-21 09:31:29 +02:00
Rossen Stoyanchev d3ed7b624d In 5.0.x we don't have Flux/Mono error with Supplier
Issue: SPR-16726
2018-04-19 13:41:01 -04:00
Rossen Stoyanchev 66bd277671 Use StringDecoder to split SSE stream
ServerSentEventHttpMessageReader had logic to split on new lines
and buffer until an empty new line (start of a new event). To account
for random data chunking, it later re-assembled the lines for each
event and split again on new lines. However bufferUntil was still
unreliable a chunk may contain nothing but a newline, which doesn't
necessarily mean an empty newline in the overall SSE stream.

This commit simplifies the above by delegating the splitting of the
stream along newlines to StringDecoder.

Issue: SPR-16744
2018-04-19 11:38:43 -04:00
Rossen Stoyanchev 881343e928 Polish tests to use WebClient retrieve() 2018-04-19 11:38:43 -04:00
Daniel Kift 922fd1e785 Polish WebFlux reference documentation 2018-04-18 11:58:37 +02:00
nkjackzhang ea8317a1f9 Fix a typo in @Nullable Javadoc 2018-04-18 11:55:13 +02:00
Rossen Stoyanchev 053ffe808f Polish (minor) in AbstractMessageReaderArgumentResolver 2018-04-17 17:58:56 -04:00
Rossen Stoyanchev daa2d37ad4 Avoid creating Exception instance if not needed
Issue: SPR-16726
2018-04-17 17:58:46 -04:00
Juergen Hoeller f800df12e3 Correctly delegate to OrderUtils.getPriority for DecoratingProxy
Issue: SPR-16739

(cherry picked from commit 2f4010e)
2018-04-17 23:38:30 +02:00
Juergen Hoeller 26652a6b83 Avoid repeated superclass introspection in findAnnotation(Method,...)
Issue: SPR-16730

(cherry picked from commit d78e27f)
2018-04-17 17:06:31 +02:00
Juergen Hoeller 4cd43dc793 Workaround for generic parameter types on inner class constructors
Issue: SPR-16734
2018-04-17 15:32:03 +02:00
sdeleuze 91c8b62817 Make ResponseSpec.expectBody Kotlin extension usable
Prior to this commit, due to KT-5464 type inference issue there was not
proper way to provide body expectations with WebTestClient. This commit
provides a workaround by updating the existing Kotlin extension to
return a Kotlin compatible API.

Issue: SPR-15692
2018-04-17 14:58:12 +02:00
Juergen Hoeller 9d37c099a8 OperatorMatches flags misguided evaluation attempts as FLAWED_PATTERN
Issue: SPR-16731

(cherry picked from commit d4a55a2)
2018-04-17 13:35:01 +02:00
Juergen Hoeller eb573d8b9e Restore original MethodMapTransactionAttributeSource matching rules
Issue: SPR-16733

(cherry picked from commit c5b524d)
2018-04-17 13:34:38 +02:00
Rossen Stoyanchev b312a62f64 Selector header name is exposed for configuration
Issue: SPR-16732
2018-04-16 23:58:47 -04:00
Rossen Stoyanchev 567733d2a1 Restore handling of 0 bytes read
Issue: SPR-16728
2018-04-16 10:01:51 -04:00
Juergen Hoeller 0f91f4b960 Local XMLUnit dependency declarations with consistent version 2.5.1
Includes upgrade to Undertow 1.4.24.

(cherry picked from commit 0754833)
2018-04-14 21:23:33 +02:00
Juergen Hoeller c1385f52c2 Polishing
(cherry picked from commit de4ff4b)
2018-04-14 21:03:59 +02:00
Sam Brannen c3bc125093 Suppress warning in SpringFailOnTimeoutTests 2018-04-14 16:44:47 +02:00
Juergen Hoeller b5922f75bb AspectJExpressionPointcut consistently resolves superinterface methods
Includes efficient check for same ClassLoader in ClassUtils.isVisible, efficient MethodMatchers check for IntroductionAwareMethodMatcher, and supertype method resolution in MethodMapTransactionAttributeSource.

Issue: SPR-16723

(cherry picked from commit b95e05d)
2018-04-14 15:49:55 +02:00
nkjackzhang bbe850d33a Fix typo in javadoc
Closes gh-1791
2018-04-13 13:16:40 +02:00
Juergen Hoeller 295929cc16 Cache-safety check for sibling loaders resolving the same classes
Issue: SPR-16714
2018-04-12 21:08:25 +02:00
Juergen Hoeller 4763154193 Consistent getTypeForFactoryMethod result for parameterized method
Issue: SPR-16720

(cherry picked from commit 6184c4e)
2018-04-12 21:08:14 +02:00
Juergen Hoeller 8f7e5e7c1a Fine-tuned JCA MessageEndpoint exception logging and propagation
Issue: SPR-16717

(cherry picked from commit 8e1ecec)
2018-04-12 21:07:44 +02:00
Juergen Hoeller cd79966c52 Revised reference example for linkable controller method signature
Issue: SPR-16710

(cherry picked from commit 7ee6130)
2018-04-12 21:07:39 +02:00
Brian Clozel 7631aa6062 Switch to Reactor Bismusth SNAPSHOTs 2018-04-12 17:01:24 +02:00
Sam Brannen 02e09098e4 Expand scope of SpringFailOnTimeoutTests
Issue: SPR-16716
2018-04-12 11:00:45 +02:00
Igor Suhorukov 230c8f93e8 Throw exception from user code in SpringFailOnTimeout even if a timeout occurs
Issue: SPR-16717
2018-04-12 11:00:35 +02:00
Rossen Stoyanchev c4296fa785 Remove write pausing in Undertow response
Using the simple example shown in the ticket but switching from
Mono<String> to Flux<String> (and 5,000,000 onNext calls) shows that
constant pausing causes significant overhead and is not worth the
trouble vs ignoring the onWritePossible in REQUESTED state.

Issue: SPR-16702
2018-04-11 14:37:35 -04:00
Rossen Stoyanchev ab78854f1b Avoid inifinite recursion in UndertowServerHttpResponse
Undertow does not provide a way to check if we can write so with the
current implementation of isWritePossible, deep recursion can occur
when writing slows down. We now use a flag to keep track of write
ChannelListener callbacks.

This commit also addresses a related issue in
AbstractListenerWriteProcessor that went undected since #3c2d186
where after a large (single) buffer that is not written fully, the
completion signal is processed before the all data is written.

Issue: SPR-16702
2018-04-11 14:37:19 -04:00
Juergen Hoeller 96a465a749 Upgrade to Tomcat 8.5.30 2018-04-11 16:27:34 +02:00