Commit Graph

7194 Commits

Author SHA1 Message Date
Phillip Webb
a3f3de223f Polish 2016-03-08 11:20:41 -08:00
Phillip Webb
644ae2c21a Merge branch '1.3.x' 2016-03-08 09:51:57 -08:00
Phillip Webb
5e722dae6a Polish 2016-03-08 09:37:13 -08:00
Andy Wilkinson
d7d2404c23 Ensure that Tomcat does not report unstopped main thread when startup fails
Following the changes made in ff99bb07, Tomcat’s WebAppClassLoader is
set as the thread context class loader of the main thread. If Tomcat
was stopped while the main thread was still running (typically as a 
result of a startup failure), this had the unwanted side-effect of
causing Tomcat to report that the application had started a thread named
main and had failed to stop it.

This commit updates TomcatEmbeddedServletContainer so that, during stop
processing, the current thread’s context class loader is reset before
Tomcat is stopped. This prevents Tomcat from incorrectly believe that
the application has started and failed to stop the main thread.

Closes gh-5357
2016-03-08 13:50:16 +00:00
Stephane Nicoll
cc2f6f4b9c Merge branch '1.3.x' 2016-03-08 10:07:06 +01:00
Stephane Nicoll
a83dae0e10 Polish contribution
Closes gh-5335
2016-03-08 10:01:14 +01:00
Eric Bottard
79cd01eb7a Fix configuration property name when group is empty
See gh-5335
2016-03-08 09:48:26 +01:00
Stephane Nicoll
9bbde5b340 Properly guard validation support
Prevent the validation support to kick in if the Validation API is not
available.

Closes gh-5353
2016-03-08 08:57:47 +01:00
Andy Wilkinson
86d87f6b8a Deprecate support for Velocity
Support for Velocity has been deprecated in Spring Framework 4.3 with
the plan being to remove it in 5.0. This commit deprecates Spring
Boot's support in 1.4, with the plan being to remove it in 2.0.

Closes gh-5276
2016-03-07 13:48:17 +00:00
Stephane Nicoll
ad53f09ed4 Improve Couchbase repository support
Previously, if Couchbase was available on the classpath but not
configured, Spring Boot would attempt to scan the project for
repositories anyway.

This commit makes sure that it only happens if an infrastructure
bean required is present. The tests have also been rewritten to better
reflect what would happen in practice.

Closes gh-5349
2016-03-07 13:19:22 +01:00
Andy Wilkinson
bbd7840785 Allow LoggingSystem to be disabled
In certain environments, such as Jetty configured with centralized
logging, Spring Boot's logging system can be problematic.

This commit adds support for using the existing LoggingSystem system
property, configured with a value of none, to disable the logging
system and rely on the standard logging configuration mechanism for
whatever logging framework is in use.

Closes gh-3571
2016-03-07 11:16:26 +00:00
Andy Wilkinson
a578488bab Merge pull request #5310 from Felipe Rotilho
* gh-5310:
  Upgrade to Gson 2.6.2
2016-03-07 10:16:41 +00:00
Felipe Rotilho
00bb936c4b Upgrade to Gson 2.6.2
Closes gh-5310
2016-03-07 10:15:57 +00:00
Stephane Nicoll
b8a315d8d0 Merge pull request #5345 from izeye/polish-20160306
* pr/5345:
  Polish
2016-03-06 09:21:22 +01:00
Johnny Lim
122270c990 Polish
Closes gh-5345
2016-03-06 09:21:00 +01:00
Stephane Nicoll
830c4c996f Update computation of ehcache statistics
Previously, the ehcache statistics were computed on the activity of the
last minute which gives a "live" overview. All others cache managers,
including JCache, provides a "cumulative" metrics (i.e. the hit/miss
ratio since the creation of the cache or the last time it got cleared).

Ths commit aligns the ehcache statistics to provide a similar semantics
as the other cache managers. The side effect is that the metrics are now
available, even if there is no cache activity at all at the moment.

Closes gh-4891
2016-03-05 09:21:11 +01:00
Stephane Nicoll
d6bc3f0bc6 Fix build
Assert using epoch time
2016-03-04 17:43:15 +01:00
Stephane Nicoll
76edaa7e1e Fix build
Add TimeZone in date assertion
2016-03-04 17:30:00 +01:00
Stephane Nicoll
f11fa0c309 Use java.util.Date rather than a raw String
This commit updates `GitInfo` to use a proper `java.util.Date` rather
than a raw String. Because the Maven and Gradle plugin do not agree on a
format, `ProjectInfoAutoConfiguration` now registers a `Converter` that
is taking care of translating the raw `String` to a `Date`.

See gh-2484
2016-03-04 17:14:34 +01:00
Andy Wilkinson
5009933788 Move to constructor injection in simple configuration classes
This commit updates "simple" configuration classes to use constructor
injection. Simple means that there are no optional dependencies
(@Autowired(required=false) is not used), and none of the dependencies
use generics.

Configuration classes that are not simple will be updated in a second
pass once https://jira.spring.io/browse/SPR-14015 has been fixed.

See gh-5306
2016-03-04 12:27:29 +00:00
Stephane Nicoll
398aed7fdb Missing entry for ProjectInfoAutoConfiguration 2016-03-04 13:26:15 +01:00
Stephane Nicoll
a603201f05 Merge pull request #5328 from anandshah123/feature/gh-5326
* pr/5328:
  Polish contribution
  Rename HealthIndicatorAutoConfigurationProperties
2016-03-04 09:08:10 +01:00
Stephane Nicoll
aba9389b25 Polish contribution
Closes gh-5328
2016-03-04 09:07:22 +01:00
Anand Shah
395c36a132 Rename HealthIndicatorAutoConfigurationProperties
Closes gh-5326
2016-03-04 09:02:56 +01:00
Phillip Webb
73cbb2f40a Polish 2016-03-03 09:14:24 -08:00
Stephane Nicoll
b0bfc11aa0 Merge pull request #5303 from garyrussell/GH-5302
* pr/5303:
  Polish contribution
  Add Cache Properties for RabbitMQ
2016-03-03 18:09:15 +01:00
Stephane Nicoll
d04155fcae Polish contribution
Closes gh-5303
2016-03-03 18:09:05 +01:00
Gary Russell
c0cb813a01 Add Cache Properties for RabbitMQ
Closes gh-3502
2016-03-03 16:46:08 +01:00
Stephane Nicoll
13f03b4161 Merge pull request #3492 from mat013/making_infoendpoint_extensible
* pr/3492:
  Polish contribution
  rebase to master
  Info endpoint
2016-03-03 16:24:29 +01:00
Stephane Nicoll
0490fbc7f8 Polish contribution
`InfoProvider` is now `InfoContributor` and contributes to the `Info`
instance via a builder. The `Info` instance is immutable. Each
contributor can be disabled via the `management.info.<name>.enabled`
key or all can be disabled using `management.info.defaults.enabled` (this
is similar to what the health endpoint does).

By default, all keys from the environment starting with `info.` are
exposed. If a `git.properties` file is present in the classpath, the
content of `GitInfo` is exposed using the `git` key.

A `SimpleInfoContributor` and `AbstractEnvironmentInfoContributor` are
available for convenience. `InfoContributor` instances can be ordered
the usual way, with a default order provided by
`InfoProviderAutoConfiguration#DEFAULT_ORDER`.

Closes gh-3492
2016-03-03 16:23:37 +01:00
Stephane Nicoll
7618802838 rebase to master 2016-03-03 14:40:21 +01:00
Meang Akira Tanaka
8bebe6dea9 Info endpoint
See gh-3492
2016-03-03 14:39:55 +01:00
Stephane Nicoll
0f820afa86 Auto-configure GitInfo
This commit moves `GitInfo` to a general "project info" area that will be
further improved with others project related information.

Deprecate `spring.git.properties` in favour of `spring.info.git.location`

Closes gh-2484
2016-03-03 14:31:00 +01:00
Stephane Nicoll
03ecdce4fb Merge pull request #5318 from izeye/polish-20160303
* pr/5318:
  Polish
2016-03-03 08:33:38 +01:00
Johnny Lim
a6c83787ef Polish
Closes gh-5318
2016-03-03 08:33:21 +01:00
Stephane Nicoll
7029ba521d Remove management.dump_requests property
Closes gh-4283
2016-03-02 17:44:25 +01:00
Andy Wilkinson
98c9744a64 Merge branch '1.3.x' 2016-03-02 11:03:41 +00:00
Andy Wilkinson
497790571f Add dependency management for logback-core
Previously, only dependency management for logback-classic was
provided. This meant that it was possible for logback-core, upon
which logback-classic depends, to have a different version.

This commit adds dependency management for logback-core, thereby
ensuring that the two dependencies will have the same version.

Closes gh-5304
2016-03-02 11:02:18 +00:00
Andy Wilkinson
367a4ed219 Merge branch '1.3.x' 2016-03-02 10:59:18 +00:00
Andy Wilkinson
40ffe4169b Improve DevTools non-embedded in-memory DB shutdown handling
Shutdown handling has been improved so that it will run after any
EntityManagerFactory beans have been closed. This ensures that Hibernate
can, if configured to do so, drop its schema during restart processing.
Without this change, a benign exception could be logged if the database
was shutdown before Hibernate.

Closes gh-5305
2016-03-02 10:55:29 +00:00
Andy Wilkinson
ef5087c5ee Upgrade to Jackson 2.7.2
Closes gh-5081
2016-03-02 07:25:55 +00:00
Andy Wilkinson
355860fd09 Remove @Autowired from constructors where class has single constructor
Closes gh-5226
2016-03-01 16:03:07 +00:00
Andy Wilkinson
3ca67e669d Polishing 2016-03-01 14:30:27 +00:00
Andy Wilkinson
8d2421938b Perform failure analysis of NoUniqueBeanDefinitionException
This commit introduces a new failure analyser for
NoUniqueBeanDefinitionException. The analyser provides details of the
consumer whose dependency could not be satisfied and the names and
sources of the non-unique beans.

This analysis requires access to the BeanFactory, so FailureAnalyzers
has been updated to support BeanFactory injection via an analyzer
implementing BeanFactoryAware.

Closes gh-5299
2016-03-01 14:28:20 +00:00
Sebastien Deleuze
6fde504a63 Fix failing Content-Type related test after SPR-13631 changes 2016-03-01 15:05:22 +01:00
Stephane Nicoll
7ceca4d83c Document how to configure a JNDI data source
Closes gh-4023
2016-03-01 11:45:30 +01:00
Andy Wilkinson
d46c9a28d5 Roll back to docker-java 2.x
This reverts 2ecb33f7 and largely reverts 2c619f8d.

docker-java 3.0 was causing a variety of problems and it appears that
we can get things working with Docker Java 2.2.x and Jackson 2.6.
2016-03-01 10:33:28 +00:00
Stephane Nicoll
df28265455 Merge branch '1.3.x' 2016-03-01 11:18:13 +01:00
Stephane Nicoll
c6c001457a Fix description of classifier attribute
See gh-5258
2016-03-01 11:15:10 +01:00
Stephane Nicoll
7f3ee2e405 Disable attach of repackaged artifact
This commit allows to generate the packaged artifact only locally by
adding a new `attach` property. If `attach` is set to `false` explicitly,
only the main artifact is installed/deployed.

Closes gh-5258
2016-03-01 11:12:59 +01:00