1304 Commits

Author SHA1 Message Date
Dave Syer
491071d6c0 Upgrade Thymeleaf to 2.1.2
Fixed gh-155
2013-12-09 17:37:01 +00:00
Dave Syer
4f085ace3a Upgrade Batch to 2.2.3 2013-12-09 10:24:23 +00:00
Dave Syer
2543ef7072 Change @Conditional for existing security configuration
Fixed by using `WebSecurityConfiguration` to detect existing
security configuration (not the annotation).

Fixes gh-151
2013-12-09 09:48:40 +00:00
Dave Syer
023faf092f Fix broken test 2013-12-06 15:45:07 +00:00
Dave Syer
bcae284dd9 Add a shim Endpoint if management context is child
When management endpoints are on a different port the HandlerMappings
are restricted to a single EndpointHandlerMapping, so the error
controller (which is a normal @Controller with @RequestMappings) does
not get mapped.

Fixed by addinga shim Endpoint on "/error" that delegates to the
ErrorController (which interface picks up an extra method).
2013-12-05 09:56:00 +00:00
Dave Syer
25d9ac6535 Remove FIXME from JPA sample 2013-12-05 09:38:10 +00:00
Dave Syer
4ab77ca893 Added exceptionIfInvalid attribute to @ConfigurationProperties
Default behaviour unchanged, but if you want to ignore validation errors
you can switch them off for indivdual beans now.

Fixes gh-144
2013-12-05 09:16:23 +00:00
Dave Syer
f57c8f52bf Check for null before trying to use ApplicationContext
Fixes gh-145
2013-12-05 08:54:13 +00:00
Dave Syer
33c38b3a51 Remove inaccurate TODO 2013-12-04 14:57:44 +00:00
Dave Syer
884fd0125a Add some handler adapter tests 2013-12-04 14:56:53 +00:00
Dave Syer
e1a09e0900 Fix formatting of header 2013-12-04 12:30:14 +00:00
Andy Wilkinson
b0c5d3254a Make "." be the CLI's default classpath
Previously, the default classpath was empty. Now, in the absence of the
user providing a classpath via the -cp option, the default classpath
will be ".". If the user does specify a classpath, the classpath that's
used will be exactly what they have specified, i.e. "." will no longer
be on the classpath unless specified by the user.

The app sample integration test has been updated to verify that "." is
only the classpath by default.

Fixes #115
2013-12-04 11:13:49 +00:00
Phillip Webb
f7f53e4e64 Fix for upstream Spring 4.0 changes 2013-12-03 11:51:51 -08:00
Dave Syer
322b03779d Upgrade Thymeleaf and Spring 2013-12-03 12:30:31 +00:00
Dave Syer
f39b044cf7 Fix packaging for Layout.NONE
Fixes gh-139
2013-12-02 14:10:56 +00:00
Ivan Sopov
40bfd295eb minor fix for javadoc 2013-12-02 14:39:10 +02:00
Dave Syer
e18a0ea6e4 Include a link to howto.md 2013-12-02 10:59:38 +00:00
Dave Syer
2104d9a1e2 Prevent failure of web app with parent context
ServerProperties formerly had an @OnMissingBeanCondition
that didn't restrict the hierarchy. It also asserts that
the current context (not including parents) contains such
a bean. This led to an inevitable failure when there was
an existing instance in the parent context.

Fixed by a) searching only the current context, b) not
adding a ServerProperties bean if the context is not a
web app.
2013-11-29 17:40:16 +00:00
Dave Syer
c03a06b52d Add test for customize container factory 2013-11-29 17:26:17 +00:00
Dave Syer
4a60e3ccf6 Unignore condition tests 2013-11-29 17:20:30 +00:00
Dave Syer
a4cb09c4eb Unignore some tests 2013-11-29 17:12:54 +00:00
Dave Syer
c16b5d277e Add test for Valve added 2013-11-29 17:06:08 +00:00
Dave Syer
6cfbcafc10 Switch to httpcomponents for better error handling in tests 2013-11-29 16:56:17 +00:00
Christian Dupuis
5661f8fc28 Test key/value sanitization 2013-11-29 15:55:06 +01:00
Christian Dupuis
078933c8fd Add actuator endpoint to expose ConfigurationProperties
This information should probably be also available from the console and log similar to AutoConfigurationReport.
2013-11-29 15:16:31 +01:00
Christian Dupuis
00c8633597 Add missing new exception class 2013-11-29 15:16:30 +01:00
Christian Dupuis
2c67e06b47 Move enablement of endpoints into AbstractEndpoint 2013-11-29 15:16:30 +01:00
Dave Syer
f1026b1202 Add JreProxySelector to handle global proxy configuration
The JreProxySelector is used it to adjust the repositories
as they are added to the GrapeEngine. It looks at standard
System proeprties like http.proxyHost and http.proxyPort
and in addition consults standard JRE Authenticator features
for credentials (falling back to System properties
http.proxyUser and http.proxyPassword).

Fixes gh-136
2013-11-29 10:12:08 +00:00
Dave Syer
e28e6d9593 More updated howtos 2013-11-29 09:46:10 +00:00
Dave Syer
19fa5b9af6 Updated howtos 2013-11-29 07:39:24 +00:00
Dave Syer
d39fc5bb92 Tidy up some tests 2013-11-28 17:35:48 +00:00
Dave Syer
9db55a3b71 Add explicit test for config file and SpringApplication 2013-11-28 16:46:21 +00:00
Dave Syer
131cfd6114 Update @SpringApplicationConfiguration after comment in 3e6c1b 2013-11-28 15:45:57 +00:00
Dave Syer
259e6a6ec1 RedisProperties prefix -> spring.redis 2013-11-28 15:12:55 +00:00
Dave Syer
e74da3fa73 FIXME test additions 2013-11-28 15:01:00 +00:00
Dave Syer
3e6c1b435f Add @SpringApplicationConfiguration (for integration testing)
Example:

    @RunWith(SpringJUnit4ClassRunner.class)
    @SpringApplicationConfiguration(classes = SampleDataJpaApplication.class)
    public class CityRepositoryIntegrationTests {

    	@Autowired
    	CityRepository repository;

Fixes gh-66.
2013-11-28 14:35:36 +00:00
Dave Syer
3e5e058b02 Ensure /error view is available 2013-11-28 14:20:45 +00:00
Dave Syer
8c9b7bd406 Use SimpleHealthIndicator if DataSource present 2013-11-28 14:20:26 +00:00
Dave Syer
16222270b8 Improve reporting of SpEL condition matching 2013-11-28 13:08:19 +00:00
Dave Syer
20bede21ad Add support for parent hierarchy in AUtoConfigurationReport 2013-11-28 11:39:27 +00:00
Dave Syer
47d079d937 Add default proxy settings from System proerties
Aether apparently doesn't use the java.net.* APIs for
TCP connections so it doesn't notice when a user sets
-Dhttp.Proxy*. To fix it is painful, and leads me to
suspect that actually we might want to parse a
settings.xml at some point (however unpalatable that
is).

For now I have added a Proxy to all RemoteRepository
instances that we create in the CLI if the user
has set -Dhttp.proxyHost (and/or -Dhttps.proxyHost for
a secure repository).

TODO: authentication. Is there a standard way to specify
that globally via system properties.

TODO: maybe use per-repository settings if provided
(e.g. in settings.xml).
2013-11-28 10:10:57 +00:00
Dave Syer
b74a9b2d06 Add tests to FIXME 2013-11-27 16:03:27 +00:00
Dave Syer
67cc427d2b Expose local port in EmbeddedServletContainer 2013-11-27 15:50:46 +00:00
Dave Syer
d1dcb015b6 Ensure only supported listeners are instantiated
Previously all EventListeners were eagerly instantiated
but that can cause problems because it happens quite early
in the lifecycle. Better to be explicit about the
supported types.
2013-11-27 15:04:05 +00:00
Dave Syer
aefec4c16a Check that SessionScope is available early 2013-11-27 14:04:09 +00:00
Dave Syer
2f6f88e370 Fix actuator sample for new shutdown property 2013-11-27 13:53:12 +00:00
Dave Syer
710dfaf9b2 Add howto for migrating existing app 2013-11-27 13:49:44 +00:00
Dave Syer
7ef9688d99 Javadocs clarification of role of DispatcherServlet 2013-11-27 10:21:38 +00:00
Dave Syer
756b5e1b60 Convert JSP sample to deployable (executable) WAR 2013-11-27 10:17:04 +00:00
Dave Syer
171c1366f9 Move shutdown enable flag to the endpoint 2013-11-26 18:01:08 +00:00