Commit Graph

7873 Commits

Author SHA1 Message Date
Juergen Hoeller
c4163c7475 Moved messaging.support.converter to messaging.converter; moved messaging.support.tcp to messaging.tcp; moved messaging.support.channel to messaging.support itself; moved handler.condition to handler itself; reworked handler.method into handler.support 2013-12-06 18:24:38 +01:00
Rossen Stoyanchev
947f3d4b2b Update Javadoc, add tests and polish spring-messaging 2013-12-05 21:30:52 -05:00
Sam Brannen
3e0b0f100c Delete unused import in MockAsyncContext 2013-12-05 21:48:49 +01:00
Sam Brannen
4957131a7b Delete sysout.println call from MBean*Tests 2013-12-05 20:40:09 +01:00
Juergen Hoeller
edeb11c556 Polishing 2013-12-04 23:58:05 +01:00
Brian Clozel
efc5074395 Document ControllerAdvice annotation
Issue: SPR-11149
2013-12-04 17:14:55 +01:00
Spring Buildmaster
0912be105a Increment version to 4.0.0.BUILD-SNAPSHOT 2013-12-03 15:09:47 -08:00
Spring Buildmaster
8a4b36479a Release version 4.0.0.RC2 2013-12-03 14:45:38 -08:00
Phillip Webb
85b0bfff58 Only consider "is" methods with boolean returns
Fix regression introduced in b25e91a5 where ReflectivePropertyAccessor
does not consider the return type for "is" getters.

Issue: SPR-11142
2013-12-03 12:01:24 -08:00
Rossen Stoyanchev
8f569264da Fix issue in GlassfishRequestUpgradeStrategy
The observed behavior was that the client does not get a response from
the WebSocket HTTP handshake. On the server the handshake actually
succeeds, the response is set correctly to status 101, and the
WebSocketHandler gets notified of the successfully established
connection.

This change flushes the ServletResponse just before returning from the
GlassfishRequestUpgradeStrategy. This is actually what Glassfish's own
TyrusServletFilter does as well at the end along with a comment that it
is a possible bug.
2013-12-03 14:42:55 -05:00
Brian Clozel
3ac14e7cd8 Document websocket XML namespace
Issue: SPR-11063
2013-12-03 18:15:21 +01:00
Rossen Stoyanchev
14468e80f3 Add principal in GlassfishRequestUpgradeStrategy 2013-12-03 12:02:41 -05:00
Phillip Webb
b1485420b6 Use port scanning for JMX tests
Attempt to fix performance build by scanning for a free JMX port.
2013-12-03 08:22:25 -08:00
Juergen Hoeller
1dff45c38a Consistent ".jetty" and ".standard" subpackages; consolidated GlassFishRequestUpgradeStrategy implementation; renamed Text/BinaryWebSocketHandler and moved them to web.socket.support 2013-12-03 17:18:24 +01:00
Rossen Stoyanchev
7713a55f6b Add test case for multivalue x-forwarded host header
Issue: SPR-11140
2013-12-03 09:24:40 -05:00
Phillip Webb
d4245610a2 Fix performance test HSQLDB error
Fix QuartzSupportTests that has been failing since the HSQLDB upgrade.
2013-12-02 23:59:32 -08:00
Phillip Webb
526555de85 Tweak times in TimedSpringRunnerTests 2013-12-02 22:47:01 -08:00
Phillip Webb
c2b56c07e5 Cache property TypeDescriptors
Attempt to improve performance by caching TypeDescriptors against bean
PropertyDescriptors in CachedIntrospectionResults.

This change is an attempt to fix the failing performance test case
`testPrototypeCreationWithOverriddenResourcePropertiesIsFastEnough` in
`AnnotationProcessorPerformanceTests`.
2013-12-02 21:55:00 -08:00
Phillip Webb
fd1b48139f Polish 2013-12-02 21:35:13 -08:00
Rossen Stoyanchev
bb5a53f7f7 Update websocket xml namespace attributes 2013-12-02 21:55:44 -05:00
Rossen Stoyanchev
cea049b791 Move websocket config tests to annotation package 2013-12-02 21:32:06 -05:00
Phillip Webb
cb46ef86c6 Fix test following ResolvableType hashcode change 2013-12-02 16:55:24 -08:00
Juergen Hoeller
6c1f62b19d EhCacheFactoryBean calls CacheManager.addCache before setStatisticsEnabled
Issue: SPR-11080
Issue: SPR-11092
(cherry picked from commit 6ce2eb9)
2013-12-03 01:37:24 +01:00
Juergen Hoeller
f5a310ad57 Polishing (backported from 3.2.x) 2013-12-03 01:37:01 +01:00
Juergen Hoeller
2a52decbbc Polishing (including removal of javadoc imports that show as package cycles in IntelliJ) 2013-12-02 23:57:00 +01:00
Juergen Hoeller
41332728f9 Use AnnotationTransactionAttributeSource class name to avoid hard dependency on transaction.annotation package 2013-12-02 23:55:41 +01:00
Juergen Hoeller
e62cd84ca2 Merged web.socket.messaging.config into web.socket.config and introduced web.socket.config.annotation 2013-12-02 23:54:38 +01:00
Phillip Webb
ab2949f2b7 Fix ResolvableType hashCode generation
Fix ResolvableType.hashCode() to use the source of the variable
resolver, rather than the resolver itself.
2013-12-02 14:47:44 -08:00
Rossen Stoyanchev
69238ba66f Move WebSocketExtension to top-level package 2013-12-02 16:53:11 -05:00
Juergen Hoeller
e3e1c1bcec Rearranged web.socket.server subpackages and introduced web.socket.config 2013-12-02 22:32:32 +01:00
Juergen Hoeller
eb8b5c435c Polishing 2013-12-02 22:32:31 +01:00
Phillip Webb
5e02a6dda3 Fix casing in spring mvc namespace attributes
Update "enableMatrixVariables" and "ignoreDefaultModelOnRedirect" to
use the more conventional XML form "enable-matrix-variables" and
"ignore-default-model-on-redirect".

Both forms are now supported by `AnnotationDrivenBeanDefinitionParser`,
with newer names being defined in the 4.0 XSD and the older names
remaining in the 3.2 XSD.

Issue: SPR-11136
2013-12-02 12:28:56 -08:00
Rossen Stoyanchev
47ef45d152 Polish websocket xml namespace
Issue: SPR-11063
2013-12-02 15:25:49 -05:00
Phillip Webb
92e144a8a8 Add a 'bill of materials' project for Maven users
Add 'spring-framework-bom' meta-project that contains the other projects
in a dependencyManagement section.

Issue: SPR-11138
2013-12-02 11:55:22 -08:00
Rossen Stoyanchev
079fb2db73 Add assert AbstractStandardRequestUpgradeStrategy 2013-12-02 13:59:17 -05:00
Brian Clozel
10f5d96a78 Add XML namespace for WebSocket config
This commit adds an XML namespace equivalent of @EnableWebSocket and
@EnableWebSocketMessageBroker. Those are <websocket:handlers> and
<websocket:message-broker> respectively.

Examples can be found in the test suite.

This commit also alters the way MessageHandler's subscribe to their
respective MessageChannel's of interest. Rather than performing the
subscriptions in configuration code, the message channels are now
passed into MessageHandler's so they can subscribe themselves on
startup.

Issue: SPR-11063
2013-12-02 12:18:33 -05:00
Juergen Hoeller
8f1fefc159 Fixed javadoc 2013-12-02 14:55:56 +01:00
Juergen Hoeller
3e4b3cad6a Always preserve target class for configuration classes in case of auto-proxying
Issue: SPR-10561
2013-12-02 14:42:17 +01:00
Juergen Hoeller
8958912c94 Extended testPrototypeCreationWithOverriddenAutowiredPropertiesIsFastEnough's deadline (since that test repeatedly failed on the CI server) 2013-12-02 13:15:27 +01:00
Juergen Hoeller
676ad125a1 Reverted arrayToList signature to return plain List
This is necessary for source compatibility with existing callers, such as code found in Spring Integration: e.g. passing the arrayToList result into a typed HashSet constructor.
2013-12-02 13:10:41 +01:00
Juergen Hoeller
bd8469990d Detect depends-on cycles and throw proper exception
Issue: SPR-7966
2013-12-02 12:39:37 +01:00
Juergen Hoeller
de890fd100 Synchronized cache creation on CacheManager
Issue: SPR-11132
2013-12-02 11:02:07 +01:00
Juergen Hoeller
ce917d5cbb Polishing around @EnableTransactionManagement
Issue: SPR-10864
2013-12-02 11:00:26 +01:00
Juergen Hoeller
e8dead247c @EnableTransactionManagement and co get detected on superclasses as well
Issue: SPR-10864
2013-12-02 10:59:30 +01:00
Phillip Webb
b0b40dade1 Detect cache hit with multiple @Cachables
Fix CacheAspectSupport to consider a cache hit from any of the multiple
@Cachables that may have been specified using the @Caching annotation.

Prior to this commit the following scenario would never produce a hit:

	@Caching(cacheable = {
		@Cacheable(value = "c1", unless = "#result.size() < 4"),
		@Cacheable(value = "c2", unless = "#result.size() > 3")
	})

Issue: SPR-11124
2013-11-26 17:13:15 -08:00
Phillip Webb
043a41e382 Consistent whitespace after imports
Update code to have a consistent number of new-line characters after
import statements.
2013-11-26 15:14:43 -08:00
Phillip Webb
15698860e1 General polish of new 4.0 classes
Apply consistent styling to new classes introduced in Spring 4.0.

- Javadoc line wrapping, whitespace and formatting
- General code whitespace
- Consistent Assert.notNull messages
2013-11-26 15:11:18 -08:00
Rossen Stoyanchev
690051f46c Add ability to customize message channels
@EnableWebSocketMessageBroker message channel configuration can now be
customized via WebSocketMessageBrokerConfigurer. It is necessary to
make this easy and even required as part of the basic configuration
since by default the message channels are backed by a thread pool of
size 1, not suitable for production use.

Issue: SPR-11023
2013-11-26 16:51:14 -05:00
Rossen Stoyanchev
e764c8d897 Fix synchronization issue in StompSubProtocolHandler
Two concurrent threads should not send a message on a single WebSocket
session at the same time, for example see:
http://docs.oracle.com/javaee/7/api/javax/websocket/RemoteEndpoint.Basic.html

In StompSubProtocolHandler it is quite possible that multiple messages
may be broadcast to a single WebSocket client concurrently.

This change adds synchronization around the sending of a message to a
specific cilent session.

Issue: SPR-11023
2013-11-26 16:51:14 -05:00
Phillip Webb
a31ac882c5 Fix various javadoc warnings 2013-11-26 13:25:37 -08:00