Commit Graph

521 Commits

Author SHA1 Message Date
Juergen Hoeller
9cc03fa8b0 Polishing 2018-03-28 02:03:31 +02:00
Juergen Hoeller
b8c92ce931 Consistent volatile access to running flag in Lifecycle implementations
Issue: SPR-16596
Issue: SPR-16488

(cherry picked from commit d4a8f76)
2018-03-28 01:17:53 +02:00
Rossen Stoyanchev
d512cca3fd Reactor2TcpClient constructor with address supplier
Issue: SPR-12452
2018-03-20 11:41:54 -04:00
Juergen Hoeller
d4af8c86b2 Polishing 2018-02-25 21:44:34 +01:00
igor-suhorukov
39ddd0f349 Polish: String function use should be optimized for single characters
(cherry picked from commit 49fd724)
2018-02-25 21:44:00 +01:00
Juergen Hoeller
0030ff8711 Polishing 2018-02-13 14:20:07 +01:00
Rossen Stoyanchev
2033f50f22 Fix regression in MappingJackson2MessageConverter
As of 4.3.13 MappingJackson2MessageConverter uses the MethodParameter
hint to obtain generic type information but it needs to be careful, and
nest one level, if the target parameter type has a Message wrapper.

Issue: SPR-16486
2018-02-12 22:03:37 -05:00
Juergen Hoeller
afe461609c Polishing (selective backports from master) 2018-02-12 13:45:53 +01:00
Juergen Hoeller
05dec6d23e Consistent use of @throws instead of @exception
(cherry picked from commit 5c813a3)
2018-02-12 13:44:17 +01:00
Rossen Stoyanchev
ef4b62caa0 Refine "." separator support for STOMP messaging
After this commit DefaultUserDestinationResolves no longer looks at
whether AntPathMatcher is configured with "." as separator and rather
expects to be explicitly told whether to keep the leading slash in
translated destinations which actually depends on what the message
broker supports (e.g. RabbitMQ "/", Artemis ".") or how it is
configured (simple broker could be either way).

There is also a minor improvement in SimpMessagingTemplate to ensure
user destinations are correctly formed based on what the
DefaultUserDestinationResolver expects. When using "." as separtor it
allows sending messages to "queue.q1" rather than "/queue.q1".

Issue: SPR-16275
2018-01-19 22:35:49 -05:00
Rossen Stoyanchev
238e9ae59f Polish MessageBrokerConfigurationTests 2018-01-19 22:24:21 -05:00
Juergen Hoeller
0b77c8835c Reduce access on user in SimpleBrokerMessageHandler.handleMessageInternal
Issue: SPR-16264
2018-01-19 19:04:57 +01:00
Rossen Stoyanchev
6dbc828aa1 MappingJackson2MessageConverter uses generic type
This is a backport of the #583201 minus use of GenericTypeResolver
which in 5.0 has been refactored to provide a getJavaType method.

Issue: SPR-16252
2018-01-04 13:17:34 -05:00
Rossen Stoyanchev
4fe94dffc0 Fix regression in StompHeaderAccessor
Issue: SPR-16265
2017-12-11 16:42:27 -05:00
Juergen Hoeller
f861f182fa Reduce access on headers for STOMP messaging
Issue: SPR-16165
2017-11-14 12:30:24 +01:00
Juergen Hoeller
6f65b638de Defensive resolution of getParameterType (actually never returning null)
Covers use of ResolvableType in overridden getParameterType variants.

Issue: SPR-16072
2017-10-17 12:15:51 +02:00
Tom Fitzhenry
1a1d767d59 Fix typo in exception message: quite -> quiet
Closes gh-1547
2017-10-03 08:25:27 +02:00
Juergen Hoeller
9fdc4404a5 Backport selected refinements from the nullability efforts
Issue: SPR-15656
2017-09-27 00:10:04 +02:00
Juergen Hoeller
d11bd64e0d TaskExecutorRegistration does not apply its default settings to a user-provided executor
Also, ChannelRegistration.setInterceptors is deprecated now: in favor of a fluently named interceptors(...) method which is documented to add the given interceptors to the channel's current list.

Issue: SPR-15962
Issue: SPR-15976

(cherry picked from commit ac9cfef)
2017-09-26 23:58:57 +02:00
Stephane Nicoll
35af7ff854 Reuse JmsTemplate's MessageConverter in JmsMessagingTemplate
This commit makes sure that any custom MessageConverter set in a
JmsTemplate used by a JmsMessagingTemplate is reused as the payload
converter of the message.

Issue: SPR-15965

(cherry picked from commit b275a06)
2017-09-26 23:58:03 +02:00
Juergen Hoeller
17f42fc97a Polishing 2017-09-08 19:42:32 +02:00
Juergen Hoeller
07a0a31565 Heart-beat log message potentially without session id
Issue: SPR-15937
(cherry picked from commit aa4ae7a)
2017-09-08 19:39:05 +02:00
Juergen Hoeller
c752ba5b38 Polishing 2017-07-19 23:55:47 +02:00
Juergen Hoeller
121a3bf670 Always invoke Jackson serialization with AtomicReference cause
Issue: SPR-15760
(cherry picked from commit 5f767a8)
2017-07-12 22:59:29 +02:00
Juergen Hoeller
e4031f290e Efficient log checks in STOMP encoder/decoder
(cherry picked from commit 122ee30)
2017-07-12 22:59:18 +02:00
Juergen Hoeller
fa09cd3737 Avoid inefficient keySet iteration in messaging classes
Issue: SPR-15553
2017-06-07 17:56:51 +02:00
Juergen Hoeller
be93ee77e4 Debug-level log entry for any Jackson exception during canConvert
Issue: SPR-15582
2017-06-07 17:56:47 +02:00
Christoph Dreis
6aeb8ef56d Optimize DefaultUserDestinationResolver.resolveDestination()
Issue: SPR-15602
2017-06-01 16:08:49 -04:00
Rossen Stoyanchev
8deec9569c Protect against NPE in DefaultSubscriptionRegistry
Follow-up fix on the recent commit:
https://github.com/spring-projects/spring-framework/commit/4fc41e

Issue: SPR-15543
2017-05-22 16:12:49 -04:00
Bao Tran
4fc41eeeb9 Fix duplicate STOMP subscription id issue
Issue: SPR-15543
2017-05-19 15:15:01 -04:00
Juergen Hoeller
597fe0720f HandlerMethod evaluates ResponseStatus annotation for early caching
Issue: SPR-15227
(cherry picked from commit 5986f88)
2017-04-13 15:54:35 +02:00
stonio
1db42081e5 Use String#isEmpty()
Closes gh-1335
(cherry picked from commit 7d062df)
2017-02-22 16:31:35 +01:00
Juergen Hoeller
34a0857628 Polishing
(cherry picked from commit d2cc97a)
2017-02-21 23:03:16 +01:00
Rossen Stoyanchev
ba0484fcac Add equals/hashcode for STOMP Subscription
Issue: SPR-15229
2017-02-21 15:10:27 -05:00
Juergen Hoeller
9834c42b5c MutableMessageHeaders serializes itself as regular MessageHeaders
Issue: SPR-15262
(cherry picked from commit 74bdcd8)
2017-02-18 00:51:02 +01:00
Juergen Hoeller
06231721c3 Consistently support CompletionStage next to CompletableFuture
Issue: SPR-15258
(cherry picked from commit 50d93d3)
2017-02-16 14:20:02 +01:00
Juergen Hoeller
3ef6697536 Refined assertion messages
Issue: SPR-15196
(cherry picked from commit 9b26fcd)
2017-01-31 16:07:09 +01:00
Juergen Hoeller
28849e0987 Revisit Assert to avoid single-arg assert methods (with refined messages)
Issue: SPR-15196
(cherry picked from commit 1b2dc36)
2017-01-31 10:28:46 +01:00
Juergen Hoeller
a98a61852f HandlerMethod pre-resolves parameter types at construction time
Issue: SPR-15186
(cherry picked from commit 8038fb9)
2017-01-25 11:12:27 +01:00
Juergen Hoeller
fcfacd9f83 Polishing
(cherry picked from commit f095aa2)
2017-01-23 23:47:01 +01:00
Rossen Stoyanchev
78a23be9bc Polish Reactor2TcpStompClient 2017-01-18 11:46:36 -05:00
Rossen Stoyanchev
48f57e3bb2 Explicitly manage event loop in Reactor2TcpStompClient
Reactor2TcpStompClient now explicitly manages a Netty EventLoopGroup
which prevents resource leaks on attempts to reconnect.

Issue: SPR-15035
2017-01-17 14:19:36 -05:00
Juergen Hoeller
caebe72083 Proper resolution of Optional.empty() for header arguments
Issue: SPR-15151
(cherry picked from commit e9db4d6)
2017-01-17 11:04:43 +01:00
Juergen Hoeller
8656e30550 Revised InvocableHandlerMethod exception messages (controller vs endpoint vs handler)
Introduces dedicated MethodArgumentResolutionException for spring-messaging invocations.

Issue: SPR-15139
(cherry picked from commit 047786a)
2017-01-16 22:43:48 +01:00
Gary Russell
db7b74feac Implement MessagingException.toString()
Issue: SPR-15091
Closes gh-1284
2017-01-05 10:25:55 +01:00
Juergen Hoeller
fa2bfdd326 Remove unused Log object from MessageHeaderAccessor
Issue: SPR-15045
(cherry picked from commit 5c48daa)
2016-12-22 23:44:34 +01:00
Juergen Hoeller
b9c4f1fa95 ResolvableType-based matching respects generic factory method return type
Includes consistent use of ResolvableType.resolve() wherever applicable.

Issue: SPR-15011
(cherry picked from commit 4c005e6)
2016-12-19 01:12:14 +01:00
Rossen Stoyanchev
69ba85b051 Backport of STOMP message header encoding improvements
Issue: SPR-14901
2016-12-08 11:33:16 -05:00
Juergen Hoeller
a7ba63d425 Shared DefaultConversionService instance for simple fallback purposes
Issue: SPR-14948
(cherry picked from commit 80931b2)
2016-12-01 14:10:39 +01:00
Christoph Dreis
8de100b116 Implement allocation-friendly method to get user count in SimpUserRegistry
SPR-14930
(cherry picked from commit a929e9c)
2016-12-01 14:09:43 +01:00