Commit Graph

11343 Commits

Author SHA1 Message Date
Rossen Stoyanchev dc7ed57c67 Support resource URL encoding at context path
Issue: SPR-13757
2015-12-10 12:24:04 -05:00
Juergen Hoeller beef5ff4c3 Polishing 2015-12-10 01:12:58 +01:00
Juergen Hoeller ca9a078d82 Polishing 2015-12-10 00:31:37 +01:00
Juergen Hoeller f119962378 SimpAnnotationMethodMessageHandler ignores empty marker annotations
Issue: SPR-13704
2015-12-10 00:30:50 +01:00
Juergen Hoeller fdc14a16ee AbstractApplicationContext clears ReflectionUtils cache as well
Issue: SPR-13783
2015-12-09 19:25:27 +01:00
Juergen Hoeller 78dad4cfc3 Jdbc4SqlXmlHandler returns null as documented (instead of throwing NPE)
Issue: SPR-13782
2015-12-09 16:09:11 +01:00
Juergen Hoeller 7f7f24949b Polishing 2015-12-09 15:13:41 +01:00
Juergen Hoeller 76f84b914f Polishing 2015-12-09 13:10:04 +01:00
Juergen Hoeller 11806b9215 Class identity comparisons wherever possible (and further polishing)
Issue: SPR-12926
2015-12-09 12:28:09 +01:00
Juergen Hoeller 4261f34b63 Consistent and lenient HttpMethod resolution across all web modules
Issue: SPR-13776
2015-12-09 12:26:44 +01:00
Stephane Nicoll 34b596c6bf Polish cache javadoc
Issue: SPR-13746
2015-12-09 11:24:53 +01:00
Juergen Hoeller 0d6545f47c Latest dependency updates (Jackson 2.6.4, Quartz 2.2.2, C3P0 0.9.5.2) 2015-12-09 11:11:03 +01:00
Juergen Hoeller 8346eeda27 Reset BytesMessage after payload extraction
Issue: SPR-13769
2015-12-08 17:12:38 +01:00
Juergen Hoeller 9589749fb2 Introduced createMethodJmsListenerEndpoint template method
Issue: SPR-13774
2015-12-08 17:07:40 +01:00
Juergen Hoeller b3115fcd85 Upgrade to Tomcat 8.0.30 and Undertow 1.3.9 2015-12-07 23:38:48 +01:00
Juergen Hoeller d2ad2c3af8 StatementCreatorUtils detects Microsoft SQL Server driver 4.0 as well
Issue: SPR-13772
2015-12-07 17:37:52 +01:00
Juergen Hoeller d0814703c4 AnnotationUtils.synthesizeAnnotation explicitly checks whether SynthesizedAnnotation is exposable
Issue: SPR-13696
2015-12-07 17:36:14 +01:00
Juergen Hoeller 40cff5e340 Polishing 2015-12-07 17:30:25 +01:00
Juergen Hoeller ee35b5ed07 Polishing 2015-12-07 12:52:06 +01:00
Juergen Hoeller 7a8a9c71b6 Javadoc fixes
Issue: SPR-13763
2015-12-07 12:51:44 +01:00
Juergen Hoeller 1585a822d6 Javadoc fixes
Issue: SPR-13765
2015-12-07 12:50:23 +01:00
Juergen Hoeller b1ef6ece9f AbstractRequestLoggingFilter unwraps request to find ContentCachingRequestWrapper
Issue: SPR-13764
2015-12-07 12:47:38 +01:00
Juergen Hoeller 20beace1bf AnnotationConfigWebApplicationContext allows for custom AnnotatedBeanDefinitionReader/ClassPathBeanDefinitionScanner
Issue: SPR-9324
2015-12-07 12:46:32 +01:00
Juergen Hoeller 9973694ed2 Polishing 2015-12-04 20:43:20 +01:00
Rossen Stoyanchev 153a23dbf9 Configure view controllers with ApplicationContext
Issue: SPR-13762
2015-12-04 13:09:37 -05:00
Juergen Hoeller 3d1ae9c604 Efficient and consistent setAllowedOrigins collection type
Issue: SPR-13761
2015-12-04 16:21:53 +01:00
Juergen Hoeller cd4ce8727e WebSocket namespace consistently applies resolvable allowed-origins value
Issue: SPR-13760
2015-12-04 16:01:14 +01:00
Juergen Hoeller d64ac32e3d ControllerAdviceBean accepts bean types without @ControllerAdvice annotation (as in 3.2)
Issue: SPR-13759
2015-12-04 13:03:00 +01:00
Juergen Hoeller 415b92b6d1 Upgrade to Hibernate 5.0.5 and Undertow 1.3.8 2015-12-04 13:01:28 +01:00
Juergen Hoeller 08b6daf1eb Polishing 2015-12-03 18:41:03 +01:00
Juergen Hoeller 08ff3a85bf Integration test for proper re-resolution of Optional @RequestPart argument
Includes a trivial refinement of RestTemplate's ResourceAccessException message.

Issue: SPR-13755
2015-12-03 12:55:32 +01:00
Juergen Hoeller c909789ea9 Avoid mismatch between cached top-level versus nested parameter type
Issue: SPR-13755
2015-12-03 12:53:18 +01:00
Rossen Stoyanchev f5e681e6e6 lastSessionCheckTime updated after session check
Issue: SPR-13745
2015-12-02 15:07:52 -05:00
Juergen Hoeller a9e5e9ecc8 Polishing 2015-12-02 15:35:42 +01:00
Juergen Hoeller 747863d503 Documented units for send-time limit and buffer-size limit
Issue: SPR-13753
2015-12-02 13:52:13 +01:00
Juergen Hoeller 3fec802b46 Fixed formatting in AOP documentation
Issue: SPR-13750
2015-12-02 13:39:26 +01:00
Juergen Hoeller a4f5c46fed MockHttpServletResponse.setIntHeader supports 'Content-Length' header as well
Issue: SPR-13752
2015-12-02 13:36:35 +01:00
Rossen Stoyanchev 4d4d2e2966 Merge pull request #928 from mhartsock/SPR-13747 2015-12-01 16:53:11 -05:00
Rossen Stoyanchev b3f0ab5284 Polish 2015-12-01 16:52:02 -05:00
mhartsock Melissa Hartsock b077b4dddb Fix media type lookup case sensitivity
Fixed a bug where the URL content negotiation "format" parameter values
were case sensitive and only lowercase values were accepted. For
example, URL query parameter format=json returned the appropriate JSON
response but format=JSON resulted in a
HttpMediaTypeNotAcceptableException and returned:

406 - The resource identified by this request is only capable of
generating responses with characteristics not acceptable according to
the request "accept" headers.

When the MappingMediaTypeFileExtensionResolver is constructed, it is
passed a map containing the media type key to MediaType mappings
defined in the ContentNegotiationConfigurer. In the constructor of
MappingMediaTypeFileExtensionResolver, the keys are converted to
lowercase and the mappings of keys to MediaTypes are added to the
ConcurrentMap<String, MediaType> mediaTypes using the lowercase
version of the keys. However, when retrieving the MediaType from a key
in the lookupMediaType method, no conversion to lowercase is performed
so any value for the URL "format" parameter other than the lowercase
version will not return the proper MediaType result.

On May 1st, 2014, a change was made to
ParameterContentNegotiationStrategy to handle cases where the content
negotiation format URL parameter does not result in a match for a
MediaType. If no match is found, a HttpMediaTypeNotAcceptableException
is thrown resulting in the 406 response above. Prior to this commit, a
null was returned instead of throwing an exception so this issue was
hidden and appeared to function correctly.

To make the media type lookup case insensitive, added a line to the
lookupMediaType method in MediaTypeFileExtensionResolver to first
convert the extension (media type key) to lowercase prior to attempting
to retrieve it from the mediaTypes map.

Issue: SPR-13747
2015-12-01 16:16:57 -05:00
Rossen Stoyanchev dacbf4cb34 Update Javadoc on UriComponentsBuilder.query 2015-12-01 16:09:05 -05:00
Juergen Hoeller e78425103e Polishing 2015-12-01 18:04:03 +01:00
Juergen Hoeller 7589c1f164 Aligned class name quoting with ConversionFailedException 2015-12-01 16:10:11 +01:00
Juergen Hoeller 44651fdf7c ObjectToObjectConverter caches detected methods/constructors
This commit reworks the arrangement to a centralized cache, avoiding any extra reflection attempts if a cache entry is known already. In the course of this, it also enforces toXXX methods to be declared as non-static now (which is the only sensible arrangement anyway).

Issue: SPR-13703
2015-12-01 16:07:21 +01:00
Brian Clozel c226753985 Do not rewrite relative links with FixedVersionStrategy
Prior to this change, the resource handling FixedVersionStrategy would
be applied on all links that match the configured pattern. This is
problematic for relative links and can lead to rewritten links such as
"/fixedversion/../css/main.css" which breaks.

This commit prevents that Strategy from being applied to such links.
Of course, one should avoid to use that VersionStrategy with relative
links, but this change aims at not breaking existing links even if it
means not prefixing the version as expected.

Issue: SPR-13727
2015-12-01 14:47:23 +01:00
Juergen Hoeller 38c21ee6bf Class identity comparisons wherever possible
Issue: SPR-12926
2015-12-01 14:11:44 +01:00
Juergen Hoeller b70af3bf57 Polishing 2015-12-01 14:10:46 +01:00
Rossen Stoyanchev fed4391f87 Fix issue in UriTemplate parsing
The recent commit 971f04 replaced the use of a NAMES_PATTERN regex in
favor of direct parsing in order to deal with nested curly braces.

The change also incorrectly replicated this logic which removes a
trailing slash after Pattern quoting (and not before):

cca037a74d/spring-web/src/main/java/org/springframework/web/util/UriTemplate.java (L207-L210)

After some more investigation there doesn't appear to be any scenario
where the quoted pattern would end with a trailing slash. It should
always end with \E (end of quote) or a ")" (end of group). Nor are
there any failing tests so this commit removes the logic altogether.

Issue: SPR-13705
2015-11-30 17:46:28 -05:00
Juergen Hoeller 998da2f45c Document destruction callback behavior for inner beans in case of scope mismatch
This commit undoes the previous refinement and rather documents the original behavior.

Issue: SPR-13739
2015-11-30 21:57:54 +01:00
Juergen Hoeller 8ed2c470be Avoid instantiation of non-selected beans in BeanFactoryAnnotationUtils.qualifiedBeanOfType
Issue: SPR-13741
2015-11-30 20:13:03 +01:00