Commit Graph

6898 Commits

Author SHA1 Message Date
Phillip Webb
f15f12d7e4 Merge branch 'gh-5083' 2016-02-06 15:51:43 -08:00
Phillip Webb
cc5d4b8b7f Add AssertJ checkstyle rule
Closes gh-5083
2016-02-06 15:51:27 -08:00
Phillip Webb
c5add2ef08 Use AssertJ in spring-boot-deployment-tests
See gh-5083
2016-02-06 15:51:27 -08:00
Phillip Webb
e214fa0949 Use AssertJ in spring-boot-integration-tests
See gh-5083
2016-02-06 15:51:27 -08:00
Phillip Webb
1cc1fc6431 Use AssertJ in spring-boot-samples
See gh-5083
2016-02-06 15:51:26 -08:00
Phillip Webb
962a598531 Use AssertJ in spring-boot-cli
See gh-5083
2016-02-06 15:51:26 -08:00
Phillip Webb
00cfe1d054 Use AssertJ in spring-boot-tools
See gh-5083
2016-02-06 15:51:26 -08:00
Phillip Webb
7f9358f4d8 Use AssertJ in spring-boot-devtools
See gh-5083
2016-02-06 15:51:25 -08:00
Phillip Webb
94677b35f8 Use AssertJ in spring-boot-actuator
See gh-5083
2016-02-06 15:15:30 -08:00
Phillip Webb
a5ae81c1c1 Use AssertJ in spring-boot-autoconfigure
See gh-5083
2016-02-06 15:15:25 -08:00
Phillip Webb
e19e3209d9 Use AssertJ in spring-boot
See gh-5083
2016-02-06 15:15:21 -08:00
Phillip Webb
8b4d801dd6 Add support for AssertJ
Add AssertJ as a managed dependency and also include it in
spring-boot-starter-test. Also provide a simple adapter class to allow
Hamcrest matchers to be used as AssertJ Conditions.

Fixes gh-5048
2016-02-06 15:06:23 -08:00
Phillip Webb
516afcd2ca Polish 2016-02-06 15:02:12 -08:00
Phillip Webb
ed01ae9ebf Use deterministic DataSource config import order
Update DataSourceAutoConfiguration so that pooled datasource
configurations are only loaded via an @Import. If left as nested
classes, the load order is JVM specific and can result in the wrong
configuration being loaded.

Closes gh-2183
2016-02-05 11:38:05 -08:00
Phillip Webb
3d0355434c Drop unneeded version tag from POM.xml 2016-02-05 11:37:08 -08:00
Andy Wilkinson
9dbef5d9b0 Remove use a separate runner thread from the Launcher
Previously, the Launcher was creating a new runner thread that would
call the application's main method. An exception thrown by this thread
is handled differently to one thrown by the JVM's main thread leading
to different exit behaviour. Furthermore, the separate thread isn't
actually necessary.

This commit removew the use of a separate runner thread from the
Launcher. This means that the JVM's exit behaviour will be consistent
and also removes the overhead of createing a starting an extra thread.

Closes gh-5006
2016-02-04 14:15:49 +00:00
Andy Wilkinson
8f57f4ca63 Merge branch '1.3.x' 2016-02-04 13:52:21 +00:00
Andy Wilkinson
c0a2c88da1 Stop referring to optional classes in BeanDefinitionLoader’s signature
Previously, BeanDefinitionLoader declared a field of type
GroovyBeanDefinitionReader which is a GroovyObject subclass. This is
problematic as BeanDefinitionLoader is always loaded but Groovy is an
optional dependency. Even on a JVM where class verification is performed
lazily, this can still cause problems if something reflectively tries
to access the class’s declared fields. On a JVM where classes are
verified at load time, it would be impossible to start a Spring Boot
application without having Groovy on the classpath.

This commit changes the field to be a BeanDefinitionReader, removing
the indirect reference to GroovyObject form BeanDefinitionLoader’s
signature. The reader is downcast to a GroovyBeanDefinitionReader in the
body of a method body that will only be invoked when Groovy is on the
classpath.

Closes gh-5040
2016-02-04 13:52:13 +00:00
Phillip Webb
34a864447f Merge branch '1.3.x' 2016-02-03 20:58:49 -08:00
Phillip Webb
43a5b77256 Ensure logback is reset after test
Update SpringBootJoranConfiguratorTests to ensure that logback
is left in a sane state. Prior to this commit, running all tests
in eclipse would fail due to ErrorPageFilterTests expecting
specific log output.
2016-02-03 20:56:45 -08:00
Phillip Webb
a80ada64c3 Formatting 2016-02-03 12:16:53 -08:00
Stephane Nicoll
4c3b11030f Merge pull request #5075 from vpavic/update-database-driver
* pr/5075:
  Fix MariaDB driver class name
2016-02-03 13:16:15 +01:00
Vedran Pavic
1bc3eb8f0a Fix MariaDB driver class name
Closes gh-5075
2016-02-03 13:16:04 +01:00
Stephane Nicoll
34d87df425 Clarify use of the spring.datasource prefix
Previously, Spring Boot mapped both `DataSourceProperties` and the actual
`DataSource` implementation to the same prefix. This results in a huge
amount of keys in the `spring.datasource` namespace  with no way to
identify those that are valid for the pooled data source in use.

This commit maps the four pooled data sources we support in four isolated
namespace, keeping `spring.datasource` only for the common settings.

These are `spring.datasource.tomcat`, `spring.datasource.hikari`,
`spring.datasource.dbcp` and `spring.datasource.dbcp2` for the Tomcat,
Hikari, Commons DBCP and Commons DBCP2 implementations respectively.

Closes gh-2183
2016-02-03 11:05:23 +01:00
Phillip Webb
bbc0dc69eb Polish 2016-02-02 16:04:09 -08:00
Stephane Nicoll
5bfccf42c4 Merge branch '1.3.x' 2016-02-02 11:24:00 +01:00
Karol Rynio
19afae7fe6 Fix typos
Closes gh-5025
2016-02-02 11:23:35 +01:00
Stephane Nicoll
2a5c686a80 Merge pull request #5060 from jvmlet/master
* pr/5060:
  Add ref to Google gRPC starter
2016-02-02 11:21:59 +01:00
jvmlet
71395a728d Add ref to Google gRPC starter
Closes gh-5060
2016-02-02 11:21:22 +01:00
Stephane Nicoll
d232475fd1 Merge pull request #5067 from izeye/polish-20160202
* pr/5067:
  Fix typos
2016-02-02 11:19:39 +01:00
Johnny Lim
46540de694 Fix typos
Closes gh-5067
2016-02-02 11:19:07 +01:00
Stephane Nicoll
f5edd53d86 Merge branch '1.3.x' 2016-02-02 08:52:01 +01:00
Stephane Nicoll
6ea74501e7 Clarify registration of ApplicationListener
Spring Boot fires event very early in the application lifecycle and we
should make crystal clear that a regular `@Bean` registration cannot be
used to register a listener on them.

Closes gh-5061
2016-02-02 08:50:32 +01:00
Stephane Nicoll
74bff1f275 Merge remote-tracking branch 'origin/1.3.x' into 1.3.x 2016-02-02 08:48:37 +01:00
Phillip Webb
acbb4e63f2 Clear caches on ApplicationContext load
Ensure that JarFile caches are cleared once the ApplicationContext has
loaded. Caches are cleared manually with the assumption that no
further class loading is likely.

Closes gh-4882
2016-01-29 21:42:19 -08:00
Phillip Webb
e2368b909b Reduce memory consumption of fat/exploded jars
Refactor `spring-boot-loader` to reduce the amount of memory required
to load fat & exploded jars. Jar files now no longer store a full list
of entry data records, but instead use an array of entry name hashes.

Since ClassLoaders often ask each JAR if they contain a particular
entry (and mostly they do not), the hash array provides a quick way to
deal with misses. Only when a hash does exist is data actually loaded
from the underlying file.

In addition to the JarFile changes, the Archive abstraction has also
been updated to reduce memory consumption.

See gh-4882
2016-01-29 21:42:18 -08:00
Phillip Webb
858a854ce1 Drop use of loggers in Launchers
Remove the use of JDK loggers in Launcher and PropertiesLauncher to
ensure allow the custom Log4j2 `LogManager` to be used with Spring Boot
applications.

Fixes gh-3815
2016-01-29 21:42:18 -08:00
Phillip Webb
50e78b9c99 Allow package private spring.factories classes
Update SpringApplication to allow classes loaded from spring.factories
to be package private.

Fixes gh-5043
2016-01-29 21:42:18 -08:00
Phillip Webb
26dfbeb8f4 Share MetadataReaderFactory
Add SharedMetadataReaderFactoryContextInitializer to ensure that a
shared caching MetadataReaderFactory is used between configuration
classes and auto-configure sorting.

Fixes gh-4993
2016-01-29 21:42:18 -08:00
Phillip Webb
26e0807d33 Merge pull request #4914 from chelseatroy/contributor_covenant
* contributor_covenant:
  Add contributor covenant
2016-01-29 10:38:49 -08:00
Chelsea Troy
5261eb2ffc Add contributor covenant
Closes gh-4914
2016-01-29 10:38:09 -08:00
Andy Wilkinson
fc29230f92 Merge branch '1.3.x' 2016-01-29 16:06:38 +00:00
Andy Wilkinson
ee409482b3 Enable the use of formatter off and on tags in Eclipse
This commit enables the use of // @formatter:off and // @formatter:on
to surround lines of code that should not be formatted. It also adds
a code template that can be used to quickly wrap the selected lines
of text with the off and on comments.

Closes gh-5050
2016-01-29 16:05:18 +00:00
Stephane Nicoll
840bb5fa5e Merge pull request #5026 from icha024/master
* pr/5026:
  Add cloudant-spring-boot-starter reference
2016-01-28 11:33:50 +01:00
Ian
68d8be70d8 Add cloudant-spring-boot-starter reference
Closes gh-5026
2016-01-28 11:33:15 +01:00
Stephane Nicoll
b01194799a Merge branch '1.3.x' 2016-01-28 11:31:41 +01:00
Vedran Pavic
93de0d7dc0 Improve systemd service documentation
Closes gh-5041
2016-01-28 11:31:28 +01:00
Stephane Nicoll
df64a74e60 Fix broken build
jetty-jndi is no longer shipped by default as of 2b2e21d but one test
checking for this wasn't updated properly.
2016-01-28 09:38:39 +01:00
Phillip Webb
f276ff4bd0 Polish 2016-01-27 16:02:36 -08:00
Stephane Nicoll
9065ddd857 Merge pull request #4411 from joshiste/cli-improvements2
* pr/4411:
  Update copyright header
  Remove closure-execution from OptionHandler
2016-01-27 18:05:34 +01:00