Commit Graph

10994 Commits

Author SHA1 Message Date
Juergen Hoeller
52fdfd59ab Polishing 2015-09-08 18:11:30 +02:00
Juergen Hoeller
5c22002d21 Latest dependency updates (Undertow 1.2.12, WebJars Locator 0.28) 2015-09-08 18:04:56 +02:00
Juergen Hoeller
a8432bc8a1 Tests for enum array with varargs (and related refinements)
Issue: SPR-13328
2015-09-08 11:13:23 +02:00
Juergen Hoeller
1feb757c54 ResourceHttpMessageConverter allows for using InputStreamResource
Issue: SPR-13443
2015-09-08 11:04:34 +02:00
Juergen Hoeller
e393c7b1ee AbstractEnvironment defensively synchronizes access to activeProfiles and defaultProfiles
Issue: SPR-13213
2015-09-08 11:03:15 +02:00
Juergen Hoeller
e214e64782 Latest dependency updates (Hibernate ORM 5.0.1, JasperReports 6.1.1, Joda-Time 2.8.2, SnakeYAML 1.16) 2015-09-04 15:11:19 +02:00
Juergen Hoeller
667fc7e4a9 Polishing 2015-09-04 14:38:47 +02:00
Juergen Hoeller
811de8e50b AbstractApplicationContext allows for re-refresh and re-close
Issue: SPR-13425
2015-09-04 14:38:23 +02:00
Sam Brannen
c663fd551a Polishing 2015-09-03 17:31:55 +02:00
Sam Brannen
734aecb15a Polish "What's New" section in reference manual 2015-09-03 17:30:14 +02:00
Brian Clozel
d3d81c2864 Add MockHttpServletResponse.getDateHeader
This change adds a new `getDateHeader` method that converts date header
Strings to long values - making tests more readable.

This feature is also documented in the "what's new section" for 4.2.
2015-09-03 16:03:46 +02:00
Brian Clozel
e81a430e61 Fix @RequestBody(required=false) support
Prior to this commit, requests with an empty body and no Content-Type
header set would fail with a HttpMediaTypeNotSupportedException when
mapped to a Controller method argument annotated with
@RequestBody(required=false).
In those cases, the server implementation considers with an
"application/octet-stream" content type and polls messageconverters for
conversion. If no messageconverter is able to process this request, a
HttpMediaTypeNotSupportedException is thrown.

This change makes sure that such exceptions are not thrown if the
incoming request has:
* no body
* no content-type header

In this case, a null value is returned.

Issue: SPR-13147
2015-09-03 14:53:43 +02:00
Juergen Hoeller
eeab7f38a2 Fixed generateETagHeaderValue's IOException handling
Issue: SPR-12081
2015-09-02 19:43:15 +02:00
Sam Brannen
93f3b9cbe0 Polish Javadoc for @EnableAsync 2015-09-02 19:08:56 +02:00
Juergen Hoeller
ec741bd5ea Latest dependency updates (Jetty 9.3.3, Netty 4.0.31, Undertow 1.2.11) 2015-09-02 16:56:04 +02:00
Juergen Hoeller
1ed1167153 Avoid ConcurrentModificationException in SingleConnectionFactory's AggregatedExceptionListener
Issue: SPR-13421
2015-09-02 16:55:09 +02:00
Sam Brannen
2caaa81afa Polishing 2015-09-02 15:37:16 +02:00
Sam Brannen
21cfa0e4ba Suppress warning in DefaultDeserializer 2015-09-02 15:25:10 +02:00
Sam Brannen
b9e461a54f Polishing 2015-09-02 15:07:49 +02:00
Juergen Hoeller
2fa1caca0c ServletWebRequest.checkNotModified avoids HttpServletResponse.getHeader calls on Servlet 2.5
Includes a revision for consistent and defensive Servlet 3.0 method calls across Spring's web abstraction (in particular, also working in debug mode where method references may get resolved early, so ternary expressions are to be avoided).

Issue: SPR-13420
2015-09-02 14:17:42 +02:00
Spring Buildmaster
d32ba954dc Next Development Version 2015-09-01 02:28:34 -07:00
Juergen Hoeller
0867a5e67f Polishing 2015-09-01 10:22:39 +02:00
Sebastien Deleuze
12937680b7 Add a section about message converters customization in the refdoc
Issue: SPR-13411
2015-09-01 00:58:29 +02:00
Sam Brannen
af905aaaea Document HtmlUnit & WebDriver deps in reference manual
This commit improves the documentation in the reference manual for the
HtmlUnit & Selenium WebDriver integration in the Spring MVC Test
framework by mentioning the group and artifact IDs required for this
functionality.

Issue: SPR-13299
2015-09-01 00:53:00 +02:00
Sam Brannen
9b1178cf71 Document support for transitive implicit aliases in @AliasFor
Issue: SPR-13405
2015-09-01 00:30:33 +02:00
Sebastien Deleuze
542e21b3f6 Polish Jackson2ObjectMapperBuilder/FactoryBean javadoc 2015-08-31 21:18:08 +02:00
Juergen Hoeller
566ea30167 Polishing 2015-08-31 17:32:33 +02:00
Juergen Hoeller
2bb7164c64 AsyncRestTemplate and FutureAdapter consistently throw ExecutionException
Issue: SPR-13413
2015-08-31 17:31:52 +02:00
Juergen Hoeller
d99717c1cb DefaultDeserializer and DeserializingConverter allow for specifying a ClassLoader
Issue: SPR-13409
2015-08-31 17:31:41 +02:00
Juergen Hoeller
d4a23b81e9 Properties values get properly converted to generic Map types (fixing 4.x regression without use of ConversionService)
Issue: SPR-13256
2015-08-31 17:20:05 +02:00
Sam Brannen
acc8c895bf Make AnnotationUtils Java 6 source compatible 2015-08-31 15:54:46 +02:00
Sam Brannen
8e14520bf5 Merge from sbrannen/SPR-13405
* SPR-13405:
  Support transitive implicit attribute aliases with @AliasFor
2015-08-31 15:48:44 +02:00
Sam Brannen
2a6716d380 Support transitive implicit attribute aliases with @AliasFor
This commit picks up where 3eacb837c2
(SPR-13345) left off by adding support for transitive implicit aliases
configured via @AliasFor.

Issue: SPR-13405
2015-08-31 15:46:12 +02:00
Sam Brannen
d899efd672 Fix typo in reference manual 2015-08-30 19:01:28 +02:00
Sam Brannen
a066143a5b Polishing
This commit removes unnecessary not-null checks for annotation
attribute alias names.
2015-08-29 16:05:26 +02:00
Sam Brannen
164bed5c3f Use implicit aliases in @TransactionalEventListener 2015-08-28 20:04:52 +02:00
Sam Brannen
3eacb837c2 Merge from sbrannen/SPR-13345
* SPR-13345:
  Support implicit attribute aliases with @AliasFor
2015-08-28 18:58:38 +02:00
Sam Brannen
d40a35ba5c Support implicit attribute aliases with @AliasFor
Spring Framework 4.2 introduced support for aliases between annotation
attributes that fall into the following two categories.

1) Alias pairs: two attributes in the same annotation that use
   @AliasFor to declare that they are explicit aliases for each other.
2) Meta-annotation attribute overrides: an attribute in one annotation
   uses @AliasFor to declare that it is an explicit override of an
   attribute in a meta-annotation.

However, the existing functionality fails to support the case where two
attributes in the same annotation both use @AliasFor to declare that
they are both explicit overrides of the same attribute in the same
meta-annotation. In such scenarios, one would intuitively assume that
two such attributes would be treated as "implicit" aliases for each
other, analogous to the existing support for explicit alias pairs.
Furthermore, an annotation may potentially declare multiple aliases
that are effectively a set of implicit aliases for each other.

This commit introduces support for implicit aliases configured via
@AliasFor through an extensive overhaul of the support for alias
lookups, validation, etc. Specifically, this commit includes the
following.

- Introduced isAnnotationMetaPresent() in AnnotationUtils.

- Introduced private AliasDescriptor class in AnnotationUtils in order
  to encapsulate the parsing, validation, and comparison of both
  explicit and implicit aliases configured via @AliasFor.

- Switched from single values for alias names to lists of alias names.

- Renamed getAliasedAttributeName() to getAliasedAttributeNames() in
  AnnotationUtils.

- Converted alias map to contain lists of aliases in AnnotationUtils.

- Refactored the following to support multiple implicit aliases:
  getRequiredAttributeWithAlias() in AnnotationAttributes,
  AbstractAliasAwareAnnotationAttributeExtractor,
  MapAnnotationAttributeExtractor, MergedAnnotationAttributesProcessor
  in AnnotatedElementUtils, and postProcessAnnotationAttributes() in
  AnnotationUtils.

- Introduced numerous tests for implicit alias support, including
  AbstractAliasAwareAnnotationAttributeExtractorTestCase,
  DefaultAnnotationAttributeExtractorTests, and
  MapAnnotationAttributeExtractorTests.

- Updated Javadoc in @AliasFor regarding implicit aliases and in
  AnnotationUtils regarding "meta-present".

Issue: SPR-13345
2015-08-28 18:56:17 +02:00
Juergen Hoeller
ff9fb9aa88 BeanWrapperImpl.getPropertyDescriptor allows for nested paths again
Issue: SPR-13403
2015-08-28 11:17:42 +02:00
Sam Brannen
90f46f9327 Suppress warnings in tests in spring-orm-hibernate4 2015-08-27 22:52:21 +02:00
Sam Brannen
527b778bf9 Clean up warnings in spring-test 2015-08-27 22:12:14 +02:00
Juergen Hoeller
491adf1f2f Polishing 2015-08-27 22:04:58 +02:00
Juergen Hoeller
0c2b787cb5 ASM fix #317578
http://forge.ow2.org/tracker/?func=detail&aid=317578&group_id=23&atid=100023
2015-08-27 22:03:36 +02:00
Brian Clozel
803d7b50b9 Skip HttpServletResponse.getStatus() on Servlet 2.5
Prior to this commit, ServletWebRequest would call
HttpServletResponse.getStatus(), which is a Servlet 3.x method.

This commit checks if this method is available before calling it, thus
keeping Servlet 2.5 compatibility.

Issue: SPR-13396
2015-08-27 20:55:50 +02:00
Juergen Hoeller
7118fcff0d MethodValidationInterceptor falls back to invocation attempt with resolved bridge method (for Hibernate Validator 5.2 compatibility)
Issue: SPR-12237
2015-08-27 19:13:29 +02:00
Sam Brannen
8af0151f1b Suppress recent deprecation warnings in tests 2015-08-27 17:57:50 +02:00
Sam Brannen
abc805819f Polish Javadoc for EmbeddedDatabaseBuilder 2015-08-27 17:27:53 +02:00
Juergen Hoeller
a1107af06f HibernateJpaDialect logs warning in case of Connection mismatch (e.g. configured release mode other than ON_CLOSE)
Related to that, HibernateTransactionManager specifically checks for active physical connections on reset as of Hibernate 5.

Issue: SPR-13269
Issue: SPR-13002
2015-08-27 16:41:41 +02:00
Juergen Hoeller
e553bb79e7 Latest dependency updates (Commons Pool 2.4.2, OkHttp 2.5) 2015-08-27 12:37:51 +02:00
Juergen Hoeller
5e43f9b88f Deprecate Commons DBCP 1.x support along with Commons Pool 1.x
Issue: SPR-12532
2015-08-27 12:37:21 +02:00