Commit Graph

10971 Commits

Author SHA1 Message Date
Venil Noronha
a5066f4d7a Add activemq starter
Closes gh-6003
2016-05-26 10:54:23 +02:00
Phillip Webb
ccdcad757a Allow template lookup caching to be disabled
Extract TemplateAvailabilityProvider caching logic to a new
TemplateAvailabilityProviders class and provide property support to
disable it. Also update DevToolsPropertyDefaultsPostProcessor to
automatically set the property.

Fixes gh-5989
2016-05-25 20:46:01 -07:00
Phillip Webb
14c7a1284e Formatting 2016-05-25 14:30:13 -07:00
Andy Wilkinson
bda2e766ac Merge branch '1.3.x' 2016-05-25 21:01:51 +01:00
Andy Wilkinson
9f425343ae Make FileSystemWatcherTests thread-safe
The list of changes is written to on one thread and read from on
another. Without some form of sychronization this is not thread-safe.

This commit makes changes a synchronized list which should guarantee
that the reading thread can see the changes made by the writing thread.
It also removes a redundant call to clear the list of changes at the
start of waitsForPollingInterval.

See gh-6038
2016-05-25 20:59:03 +01:00
Andy Wilkinson
ac5afb142c Merge branch '1.3.x' 2016-05-25 17:42:51 +01:00
Andy Wilkinson
a98d1a41a4 Run Maven Plugin's integration tests when full profile is active
Closes gh-6036
2016-05-25 17:42:08 +01:00
Andy Wilkinson
fc1814919c Add jars that should have been commited in 6ed63a6 2016-05-25 17:41:12 +01:00
Stephane Nicoll
50e0bb2d9c Improve DataJpaTest documentation
As `@DataJpaTest` is meta-annotated with `@Transactional`, all data jpa
tests are transactional and rollback at the end of each test. It is
possible to tune that in many ways, including disabling the transaction
per test or per test class.

This commit improves the doc to explain those concepts.

Closes gh-5993
2016-05-25 11:28:16 +02:00
Andy Wilkinson
ccd19ce2c3 Merge branch '1.3.x' 2016-05-24 17:25:15 +01:00
Andy Wilkinson
275651e89a Skips Cassandra and Elasticsearch tests on Windows
Neither Cassandra nor Elasticsearch starts reliably on Windows. This
commit adds a custom class rule to the associated sample application
tests to skip them on Windows. A class rule is used rather than a
Unit assumption as we want to avoid starting Elasticsearch (done by
the application context) and Cassandra (done by a test execution
listener) and an assumption would be too late.
2016-05-24 17:22:48 +01:00
Stephane Nicoll
6ed63a6eff Add support of system-scoped dependencies
In Maven land, provided and system-scope dependencies are very similar,
the latter being an special kind that allows you to specify the path to
the artifact rather than using the repository to locate it.

Prior to this commit, the repackage goal of the maven plugin was
inconsistent as it would repackage provided-scope dependencies but would
ignore the system-scoped ones.

This commit adds an extra boolean flag, `includeSystemScope` to control
this behaviour. For backward compatibility reasons, its default value is
`false`.

Closes gh-2224
2016-05-24 16:25:54 +02:00
Andy Wilkinson
98a039ea99 Clarify references to Commons Logging in the documentation 2016-05-24 14:43:47 +01:00
Stephane Nicoll
9ab5c09905 Add reference to @TestPropertySource in the doc
Closes gh-5899
2016-05-24 09:07:26 +02:00
Stephane Nicoll
8201c8d1f6 Merge pull request #5074 from vpavic:multiple-management-roles
* pr/5074:
  Polish contribution
  Support configuration of multiple management roles
2016-05-23 18:40:57 +02:00
Stephane Nicoll
b02aba4c75 Polish contribution
Closes gh-5074
2016-05-23 17:38:45 +02:00
Vedran Pavic
20fa1b3b48 Support configuration of multiple management roles
Closes gh-5045
2016-05-23 17:15:44 +02:00
Andy Wilkinson
e9a226c8f8 Fix handling of annotations on super classes in AnnotationsPropertySource
Closes gh-6006
2016-05-23 12:36:17 +01:00
Stephane Nicoll
3d0b682f0f Document none cache type
Closes gh-6004
2016-05-23 07:09:06 +02:00
Stephane Nicoll
9182ada260 Polish doc
Closes gh-6009
2016-05-23 06:52:28 +02:00
Dave Syer
ea469f9bc2 Fix spelling error in class name in spring.factories 2016-05-22 10:59:58 +01:00
Dave Syer
ba824b240b Add uuid generator to RandomValuePropertySource
A well-formed string represenation of a UUID can now be generated
by ${random.uuid}.
2016-05-22 10:36:54 +01:00
Stephane Nicoll
3cff46f4da Merge pull request #6007 from izeye:rename
* pr/6007:
  Rename AutoConfigurationJson to AutoConfigureJson
2016-05-21 09:44:34 +02:00
Johnny Lim
189f96687d Rename AutoConfigurationJson to AutoConfigureJson
Closes gh-6007
2016-05-21 09:44:04 +02:00
Stephane Nicoll
4213c1575a Polish doc
Closes gh-5999
2016-05-20 13:00:08 +02:00
Stephane Nicoll
c3201a1e91 Revert "Cache resolved error template view names"
See gh-5989
2016-05-18 17:56:27 +02:00
Stephane Nicoll
6698af08df Replace Starter POM to Starter in the documentation
"Starter POM" is a confusing term as it implies the starter may be a
POM while it's actually a jar artifact like any other dependency. To
reduce the confusion (especially in the way such starter should be
declared in the build), the term Starter POM has been renamed to Starter.

Closes gh-5966
2016-05-18 08:55:42 +02:00
Stephane Nicoll
dcf3a56bd5 Polish 2016-05-17 09:48:59 +02:00
Stephane Nicoll
3805fc7455 Polish 2016-05-17 08:55:59 +02:00
Phillip Webb
f3e630933a Add OAuth PrincipalExtractor strategy interface
Update `UserInfoTokenServices` to use a PrincipalExtractor interface
to extract the principal.

Fixes gh-5186
2016-05-16 19:21:52 -07:00
Phillip Webb
7f45485e61 Provide explicit force request/response properties
Update HttpEncodingProperties to offer explicit `force-request` and
`force-reponse` properties in additional to the existing `force`
property.

Closes gh-5459
2016-05-16 18:43:57 -07:00
Phillip Webb
68983400fb Propogate startup failures to management context
Update EndpointWebMvcAutoConfiguration so that ApplicationFailedEvents
cause the management context to close.

Prior to this commit if an application failed to start (for example
because `server.port` was already in use) the management context would
remain open and the application would not exit.

Fixes gh-5388
2016-05-16 17:26:03 -07:00
Phillip Webb
f0b6d346d7 Filter scoped target proxy beans from Mockito
Update MockitoPostProcessor to filter bean names that match
`ScopedProxyUtils.isScopedTarget` from the candidates list.

Fixes gh-5724
2016-05-16 13:56:13 -07:00
Phillip Webb
682f20ebf7 Merge pull request #5972 from izeye/test-20160514
* pr/5972:
  Fix Mockito tests to align with name and comments
2016-05-16 13:22:31 -07:00
Johnny Lim
5759f685e5 Fix Mockito tests to align with name and comments
Fixup Mockto tests where the test implementation didn't align with the
name of the test or the test Javadoc.

Closes gh-5972
2016-05-16 13:20:01 -07:00
Phillip Webb
2fc86b2d5a Only attempt mock reset on instantiated singletons
Update ResetMocksTestExecutionListener to only attempt a mock reset when
a singleton has actually been created.

Fixes gh-5870
2016-05-16 13:03:04 -07:00
Phillip Webb
bcfa2e6676 Make TestRestTemplate not extend RestTemplate
Update TestRestTemplate so that it no longer directly extends
RestTemplate. Prior to this commit it was possible that TestRestTemplate
could interfere with user defined RestTemplate beans.

TestRestTemplate offers the same methods as RestTemplate so should be
a drop-in replacement. If access is needed to the actual underlying
template the `getRestTemplate()` method should be used.

Fixes gh-5915
2016-05-16 12:35:31 -07:00
Andy Wilkinson
1947b92481 Avoid exception from dropping non-existent constraint in Data REST sample
Hibernate 5.1 logs an ugly but benign exception when using an in-memory
HSQL database when it tries to drop a non-existent constraint.

This commit changes the Spring Data REST sample to use H2 rather than
HSQL. This prevents the unwanted exception from occurring as Hibernate's
H2 dialect returns false from dropConstraints.
2016-05-16 20:27:35 +01:00
Phillip Webb
00fbb5c3d9 Polish 2016-05-16 12:00:03 -07:00
Dave Syer
46134b58b8 Fix stupid checkstyle violations 2016-05-16 14:52:11 +01:00
Dave Syer
684c8c81a3 Extract user info rest template into a factory
Instead of using a @Bean, it is better to use an opaque factory
for an internal dependency that users are not going to want in
the context. OAuth2RestTemplate is a common enough bean type that
creating on in autoconfig makes it hard for users to add their own
for business use.

See gh-5967
2016-05-16 14:06:54 +01:00
Stephane Nicoll
3734b666df Merge pull request #5975 from caseyscarborough:remove-unchecked-casts
* pr/5975:
  Remove unchecked casts
2016-05-16 13:53:41 +02:00
Casey Scarborough
84d3b6a41a Remove unchecked casts
Closes gh-5975
2016-05-16 13:53:18 +02:00
Phillip Webb
4023637b07 Remove accidentally comitted SampleTest 2016-05-14 11:28:42 -07:00
Phillip Webb
cd365bcae1 Improve @PropertyMapping error message
Improve the message thrown when a @PropertyMapping is used in
combination with a @Component to include the actual annotations that
are causing the problem.

Fixes gh-5897
2016-05-13 20:09:03 -07:00
Phillip Webb
66b69f4346 Deprecate setProperties on ConfigurationFactory
Deprecate `PropertiesConfigurationFactory.setProperties()` since it was
only being used in tests.

Fixes gh-5930
2016-05-13 20:09:03 -07:00
Phillip Webb
c15c146021 Cache resolved error template view names
Fixes gh-5933
2016-05-13 20:09:02 -07:00
Johnny Lim
29898c73d3 Remove superflous if in MockitoPostProcessor
The `if` in registerSpies() is not required as it's covered by the
Assert check.

Closes gh-5889
2016-05-13 20:09:02 -07:00
Phillip Webb
6cdbdf9ad3 Polish 2016-05-13 20:09:02 -07:00
Vedran Pavic
a1ac934bee Ignore special variable related JVM output in CommandLineInvoker
Closes gh-5883
2016-05-13 16:31:49 +01:00