Add note to @CrossOrigin javadoc

Issue: SPR-13857
This commit is contained in:
Rossen Stoyanchev
2016-01-14 14:13:50 -05:00
parent 31a3607de6
commit e56587dcc3

View File

@@ -29,6 +29,14 @@ import org.springframework.core.annotation.AliasFor;
*
* <p>By default, all origins and headers are permitted.
*
* <p><b>NOTE:</b> {@code @CrossOrigin} will only be processed if an an appropriate
* {@code HandlerMapping}-{@code HandlerAdapter} pair is configured such as the
* {@code RequestMappingHandlerMapping}-{@code RequestMappingHandlerAdapter} pair
* which are the default in the MVC Java config and the MVC namespace.
* In particular {@code @CrossOrigin} is not supported with the
* {@code DefaultAnnotationHandlerMapping}-{@code AnnotationMethodHandlerAdapter}
* pair both of which are also deprecated.
*
* @author Russell Allen
* @author Sebastien Deleuze
* @author Sam Brannen