Commit Graph

285 Commits

Author SHA1 Message Date
Andy Wilkinson
f892363c0f Merge branch '1.5.x' 2017-04-04 12:30:34 +01:00
Andy Wilkinson
155d55097f Merge branch '1.4.x' into 1.5.x 2017-04-04 12:21:43 +01:00
Andy Wilkinson
47de05b52c Update Devtools to ignore manifest Class-Path entries that do not exist
Closes gh-8623
2017-04-04 12:15:51 +01:00
Phillip Webb
b76ca0bf8f Restructure web auto-configuration
Restructure `org.springframework.boot.autoconfigure.web` to better align
with the new package structure in `spring-boot`.

Auto-configuration is now split into client, servlet and reactive
sub-packages. In addition a new `http` package now handles common
HTTP concerns.

Fixes gh-8616
2017-03-14 22:06:28 -07:00
Phillip Webb
69b72874ea Extract logging listeners
Separate logging ApplicationListeners classes to a different package
so that the root `logging` package is no longer aware of `context`
concerns.

Fixes gh-8611
2017-03-14 13:45:53 -07:00
Phillip Webb
67556ba8ea Restructure embedded web server packages
Rework `org.springframework.boot.context.embedded` to relocate classes
to `org.springframework.boot.web`. Packages are now organized around
the following areas:

Packages for shared concerns, for example the `WebServer` interface
to start/stop a server and the common configuration elements:
- org.springframework.boot.web.context
- org.springframework.boot.web.server

Servlet specific packages:
- org.springframework.boot.web.servlet.server
- org.springframework.boot.web.servlet.context
- org.springframework.boot.web.servlet.filter

Reactive specific packages:
- org.springframework.boot.web.reactive.context
- org.springframework.boot.web.reactive.server

Embedded server implementations (both reactive and servlet):
- org.springframework.boot.web.embedded

In addition:

- Rename `EmbeddedServletContainerFactory` to `ServletWebServerFactory`
  to align with the `ReactiveWebServerFactory`.
- Rename `EmbeddedWebApplicationContext` to
  `ServletWebServerApplicationContext` and
- Rename `EmbeddedReactiveWebApplicationContext` to
  `ReactiveWebServerApplicationContext`.
- Add checkstyle rules to restrict imports.
- Fixup all affected code to use the correct imports and local names.

Fixes gh-8532
2017-03-12 21:08:25 -07:00
Phillip Webb
d8f827d224 Cleanup and format code 2017-03-06 17:08:09 -08:00
Phillip Webb
425dbc3e52 Update copyright header for edited files 2017-03-06 15:04:07 -08:00
Spring Buildmaster
d23fa24340 Next Development Version 2017-03-03 16:18:26 +00:00
Spring Buildmaster
2a83e80a9b Next Development Version 2017-03-03 14:39:21 +00:00
Vedran Pavic
1c789f1a8d Remove dependency management for hibernate-entitymanager
Closes gh-8433
2017-03-02 18:31:53 +01:00
Andy Wilkinson
23cda9012c Merge branch '1.5.x' 2017-02-28 12:26:04 +00:00
Andy Wilkinson
627edc0f7a Use a different approach to disable HATEOAS Objenesis instance's cache
Previously, reflection was used to set the OBJENESIS field of
DummyInvocationUtils with an Objenesis instance that does not use
caching. This has stopped working as the field is now declared final.

This commit updates the approach take by HateoasObjenesisCacheDisabler
to disable Objenesis's cache. Rather than changing the value of the
OBJENESIS field on DummyInvocationUtils, the cache field on the
ObjenesisStd instance is set to null instead. This has the desired
effect of disabling Objenesis's caching.

See gh-3784
Closes gh-8335
2017-02-28 12:24:19 +00:00
Phillip Webb
a4bcd20b64 Merge branch '1.5.x' 2017-02-27 20:43:18 -08:00
Phillip Webb
ca1540cefe Update header copyright for changed files 2017-02-27 20:41:18 -08:00
Brian Clozel
aeef41c977 Separate container customization from ServerProperties
This commit creates a separate
`ServerPropertiesServletContainerCustomizer` that holds the servlet
container customization code, separating that concern from the server
configuration keys.

See gh-8066
2017-02-08 09:55:07 +01:00
Brian Clozel
12d883f6b9 Introduce "server.servlet" configuration prefix
This commit refactors the `ServerProperties` property keys and
introduces a separate "server.servlet" namespace to isolate
servlet-specific properties from the rest.

Closes gh-8066
2017-02-07 16:48:22 +01:00
Brian Clozel
8619d6a229 Rename EmbeddedServletContainer -> EmbeddedWebServer
This contract is not specific to servlet containers and should be
reused by all web server implementations (including reactive variants).

Fixes gh-8208
2017-02-06 17:44:26 +01:00
Stephane Nicoll
6af6e8e31b Remove auto-configuration for ServerProperties
This commit removes `ServerProperties` and `ManagementServerProperties`
auto-configurations. Those properties objects are now created using
`@EnableConfigurationProperties` only.

Closes gh-8108
2017-02-06 14:00:50 +01:00
Stephane Nicoll
cfdc75d384 Merge branch '1.5.x' 2017-02-06 10:38:16 +01:00
Johnny Lim
0adab8a2be Use logical 'and' instead of bitwise 'and'
Closes gh-8198
2017-02-06 10:35:13 +01:00
Andy Wilkinson
95f659f4f9 Add new WebApplicationType enum to pave the way for Web Flux support
Closes gh-8077
2017-01-30 20:26:24 +00:00
Spring Buildmaster
5c12500366 Next Development Version 2017-01-30 20:10:13 +00:00
Spring Buildmaster
a2696bf873 Next Development Version 2017-01-30 11:40:24 +00:00
Eddú Meléndez
3d52c86a21 Annotate interfaces with @FunctionaInterface
Closes gh-6857
2017-01-27 16:41:01 +00:00
Spring Buildmaster
ed1ce140c0 Next Development Version 2017-01-26 14:20:39 +00:00
Brian Clozel
de98c4b3ff Provide Reactor 3 auto-configuration
This commit provides auto-configuration for the Reactor Core 3 library.
A new configuration namespace, "spring.reactor" allows to configure
hooks on operators, like "spring.reactor.stacktrace-mode.enabled".

This property is enabled automatically by devtools, since it improves
the developer experience and provides full stacktrace information when
exceptions occur (but at a performance cost).

Fixes gh-7302
2017-01-26 10:35:12 +01:00
Andy Wilkinson
9bba73a1a9 Upgrade to Thymeleaf 3 and drop support for Thymleaf 2
This commit raises the minimum supported version of Thymeleaf to
3.0.x. It also upgrades Spring Social to a version that is compatible
with Thymeleaf 3.

Closes gh-7450
Closes gh-6258
See gh-7885
2017-01-25 13:59:09 +00:00
Stephane Nicoll
661fd848eb Merge branch '1.5.x' 2017-01-25 11:02:32 +01:00
Stephane Nicoll
505e7f75ea Polish contribution
Closes gh-8089
2017-01-25 11:01:53 +01:00
dreis
d58f38f6f6 Use String.replace() with single char if possible
See gh-8089
2017-01-25 11:01:52 +01:00
Phillip Webb
8ffaa54e74 Merge branch '1.5.x' 2017-01-23 23:45:44 -08:00
Madhura Bhave
ca435512c0 Introduce spring-boot-autoconfigure-processor
Add an annotation processor that generates properties files for certain
auto-configuration class annotations. Currently attribute values from
@AutoConfigureOrder, @AutoConfigureBefore, @AutoConfigureAfter and
@ConditionalOnClass annotations are stored.

The properties file will allow optimizations to be added in the
`spring-boot-autoconfigure` project. Primarily by removing the need
to ASM parse as many `.class` files.

See gh-7573
2017-01-23 22:14:56 -08:00
Phillip Webb
2c89d9918f Relocate AutoConfigurations from root package
Move PropertyPlaceholder and MessageSource auto-configuration from the
root package to the `context` subpackage.

Fixes gh-8071
2017-01-23 17:32:45 -08:00
Andy Wilkinson
4548af2966 Merge branch '1.5.x' 2017-01-19 09:28:21 +00:00
Andy Wilkinson
531cf5d4f6 Merge branch '1.4.x' into 1.5.x 2017-01-19 09:28:14 +00:00
Andy Wilkinson
6a0fb8e44c Update DevTools' ResourceLoader to delegate to user's custom loader
Previously, when DevTools' was used it would set the application
context's ResourceLoader and overwrite any custom ResourceLoader that
had been configured. On the rare occasion when the user had customized
the ResourceLoader this meant that the customization was lost and
certain resources would become unavailable.

This commit updates DevTools' ResourceLoader to delegate a custom
ResourceLoader if one has been configured. If one has not been
configured it delegates as before, i.e. to
WebApplicationContextResourceLoader for web applications and to
DefaultResourceLoader for all others apps.

Closes gh-8010
2017-01-19 09:28:09 +00:00
Andy Wilkinson
5f4848cf21 Merge branch '1.5.x' 2017-01-17 10:39:16 +00:00
Andy Wilkinson
6cab03de0b Merge branch '1.4.x' into 1.5.x 2017-01-17 10:39:09 +00:00
Andy Wilkinson
69320180d9 Make FileSystemWatcherTests.waitsForPollingInterval more robust
The intent of the test is to:

1. Make a change
2. Sleep for long enough for that change to be picked up
3. Make another change
4. Stop that watcher after 1 further scan has been performed
5. Assert that a further scan was performed by checking that two
   separate sets of changes (step 1 and step 3) have been picked up

Previously, step 2 relied on simply sleeping for a period of time
longer than the polling interval. In reality, the polling interval
is only a minimum time between scans and the actual time between them
depends on thread scheduling, GC pauses, etc. This lead to the
test failing intermittently if the scan didn't happen in a timely
manner.

This commit removes the sleep and replaces it with a while loop that
waits for first change to be picked up. This ensures that the second
change will be detected separately from the first and that two
separate change sets should always be available once the watcher has
stopped.

See gh-7782
2017-01-17 10:30:47 +00:00
Phillip Webb
77f9bb09ca Further Polish Mockito 2 support
See gh-7770
2017-01-05 14:29:29 -08:00
Stephane Nicoll
506f6497c0 Merge branch '1.5.x' 2017-01-04 09:56:19 +01:00
Johnny Lim
f915ae197a Polish 2017-01-04 09:53:45 +01:00
Phillip Webb
a90bad37bd Merge branch '1.5.x' 2016-12-30 13:29:18 -08:00
Phillip Webb
b76978ff7e Try to prevent Travis build failures
Update LiveReloadServerTests which seems to be failing intermittently
on Travis.
2016-12-30 12:22:37 -08:00
Phillip Webb
53f1df86a2 Merge branch '1.5.x' 2016-12-30 12:17:28 -08:00
Phillip Webb
aacf5d660f Update copyright year for changed files 2016-12-30 11:53:51 -08:00
Phillip Webb
519f9c6c54 Merge branch '1.5.x' 2016-12-28 15:35:32 -08:00
Phillip Webb
8b69856fc9 Polish 2016-12-28 15:23:26 -08:00
Phillip Webb
97d7ffd8e8 Merge branch '1.4.x' into 1.5.x 2016-12-28 14:48:05 -08:00