Commit Graph

10971 Commits

Author SHA1 Message Date
Phillip Webb
778e3eb091 Polish 2015-06-24 16:15:12 -07:00
Stephane Nicoll
bc9321734f Add support for property hint
Create a new section in the meta-data called "hints" where users can
provide hints about a given property. The most basic use case for now
is to provide a list of values that a property can have. Each value may
have a description.

This sample JSON provides a basic example for a property called `foo.mode`
that exposes 3 values: "auto", "basic" and "advanced".

```
 "hints": [
    {
      "id": "foo.mode",
      "values": [
        {
          "value": "auto",
          "description": "Some smart description."
        },
        {
          "name": "basic"
        },
        {
          "name": "advanced"
        }
      ]
    }
]
```

This information can be read by tools (such as IDE) and offer an
auto-completion with the list of values.

Closes gh-2054
2015-06-24 18:53:11 +02:00
Andy Wilkinson
9aa445bf46 Merge branch '1.2.x' 2015-06-24 17:13:39 +01:00
Andy Wilkinson
f8fdcc1312 Include value of java.io.tmpdir in message when createTempFile fails
If java.io.tmpdir is configured to a directory that does not exist,
calls to File.createTempFile will fail with an IOException with the
message "The system cannot find the path specified". Unfortunately,
the path the was specified is not included in the message.

Rather than trying to automatically create the directory in what may
be a misconfigured location, we now include the value of
java.io.tmpdir in our own exception's message. Hopefully this will
help users to figure out what they've done wrong.

Closes gh-3307
2015-06-24 17:13:18 +01:00
Stephane Nicoll
af1afeaf48 Merge branch '1.2.x' 2015-06-24 17:20:49 +02:00
Stephane Nicoll
982b81c675 Fix datasource metrics doc
The maximum and minimum number of connections are no metrics so these
are not exposed. Fix the doc that stated the contrary.

Fixes gh-3319
2015-06-24 17:20:31 +02:00
Stephane Nicoll
41b4d41f11 Remove dead code 2015-06-24 15:57:43 +02:00
Stephane Nicoll
e9baa779cc Remove dead code 2015-06-24 15:52:27 +02:00
Stephane Nicoll
1d66aa35ed Fix typo 2015-06-24 15:20:20 +02:00
Stephane Nicoll
117d6b0da3 Fix typo 2015-06-24 11:12:42 +02:00
Phillip Webb
fe57101076 Merge pull request #2294 from joshiste/2294
* pr/2294:
  Add /logfile MVC actuator endpoint
2015-06-23 17:32:44 -07:00
Johannes Stelzer
308a5eaff5 Add /logfile MVC actuator endpoint
Add a `/logfile` endpoint which can be used to fetch the contents of
the log file (if one is being used).

Fixes gh-2137
Closes gh-2294
2015-06-23 17:14:40 -07:00
Phillip Webb
880f31ae2e Merge pull request #2300 from drumonii/master
* pr/2300:
  Add a SpringBootVersion class like SpringVersion
2015-06-23 14:51:57 -07:00
drumonii
8b04973244 Add a SpringBootVersion class like SpringVersion
Provide a static utility method to get the Spring Boot version based on
the implementation version of SpringApplication's package. Similar to
Spring Frameworks' SpringVersion class.

Fixes gh-2300
2015-06-23 14:51:20 -07:00
Phillip Webb
69c44fafc7 Merge pull request #2704 from sailorgeoffrey/master
* pr/2704:
  Add support for ANSI colored resource banners
2015-06-23 14:31:59 -07:00
Geoffrey Chandler
d6200389eb Add support for ANSI colored resource banners
Add AnsiPropertySource which allows named ANSI codes to be resolved
and update ResourceBanner to include it.

This commit also deprecates constants defined in AnsiElement and
replaces them with AnsiStyle, AnsiColor and AnsiBackground enums.

Closes gh-2704
2015-06-23 14:31:49 -07:00
Phillip Webb
9f143ad9ab Merge pull request #2901 from creactiviti/freemarker-autoconfigure-preferfilesystemaccess
* pr/2901:
  Add Freemarker `prefer-file-system-access` support
2015-06-23 11:34:22 -07:00
cohee016
d948ec5810 Add Freemarker prefer-file-system-access support
Add a `spring.freemarker.prefer-file-system-access` property and update
FreeMarkerAutoConfiguration to support it.

Fixes gh-2901
2015-06-23 11:34:02 -07:00
Phillip Webb
61fc4f3f12 Polish copyright headers 2015-06-23 10:22:14 -07:00
Phillip Webb
d3007fae94 Polish formatting 2015-06-23 09:54:21 -07:00
Phillip Webb
ab18fb29a3 Merge branch '1.2.x' 2015-06-23 09:46:12 -07:00
Phillip Webb
16e7c99e4d Polish formatting 2015-06-23 09:45:54 -07:00
Stephane Nicoll
d0698bd8ed Remove unnecessary System.out in tests 2015-06-23 15:57:40 +02:00
Andy Wilkinson
0bb0f32c88 Reinstate code in Data REST sample that went AWOL in 1ce617f1 2015-06-23 14:44:43 +01:00
Andy Wilkinson
eea7050237 Merge branch '1.2.x' 2015-06-23 14:14:32 +01:00
Onur Kağan Özcan
2d153ca745 Upgrade to Spring Mobile 1.1.4.RELEASE
Closes gh-3308
2015-06-23 14:13:50 +01:00
Stephane Nicoll
909dc374cf Merge branch '1.2.x' 2015-06-23 14:18:28 +02:00
Matt Benson
80deaf6456 Fix absolute file detection on Windows
Closes gh-3299
2015-06-23 14:16:54 +02:00
Stephane Nicoll
dc7d17091a Merge pull request #3297 from Quantas/master
* pr/3297:
  Prevent restart when META-INF/maven/** changes
2015-06-23 14:07:30 +02:00
Andrew Landsverk
487ab1a60a Prevent restart when META-INF/maven/** changes
These files are modified by Eclipse for some reason when you change files
like Thymeleaf HTML files. `META-INF/maven/**` has been added to the
default exclusion.

Closes gh-3295
Closes gh-3297
2015-06-23 14:05:25 +02:00
Dave Syer
92a6e3188b Correct Spring Data REST docs 2015-06-23 09:41:28 +01:00
Phillip Webb
0f977ce864 Polish 2015-06-23 00:47:32 -07:00
Phillip Webb
1ce617f1ae Polish sample package names 2015-06-23 00:47:12 -07:00
Phillip Webb
9c0335fc29 Merge pull request #2764 from bsodzik/1.2.x
* pr/2764:
  Add `spring.pid.fail-on-write-error` support
2015-06-22 23:44:57 -07:00
Tomasz Przybyła
becced5f0b Add spring.pid.fail-on-write-error support
Update `ApplicationPidFileWriter` to support a 'fail on write error'
properties which allows the user to exit the application if the PID
file cannot be written.

This commit also deprecates `spring.pidfile` in favor of
`spring.pid.file` so that the new property can be added without overlap.

Fixes gh-2764
2015-06-22 23:43:58 -07:00
Phillip Webb
c13ff96b78 Fix misnamed jOOQ sample module 2015-06-22 22:12:28 -07:00
Phillip Webb
d9466cfcf5 Merge pull request #2804 from aahlenst/jooq-starter
* pr/2804:
  Document jOOQ support
  Add jOOQ sample application
  Add support for jOOQ
2015-06-22 22:06:42 -07:00
Phillip Webb
7fd07b6588 Document jOOQ support
Closes gh-2804
2015-06-22 21:20:12 -07:00
Phillip Webb
ab1cc829c1 Add jOOQ sample application
See gh-2804
2015-06-22 21:20:12 -07:00
Andreas Ahlenstorf
a08b09563b Add support for jOOQ
Add auto-configuration and a starter POM for jOOQ.

See gh-2804
2015-06-22 21:20:12 -07:00
Andy Wilkinson
9da14fe62a Merge branch '1.2.x' 2015-06-22 16:27:27 +01:00
Andy Wilkinson
6fd3042462 Align servlet container error handling with executable jar/war behavior
Previously, when an exception was thrown by a Controller in an
application deployed to a servlet container the exception that was
handled would be Spring Framework’s NestedServletException rather than
the exception thrown by the application. Furthermore, when an exception
was thrown or the response was used to send an error, the
javax.servlet.error.request_uri request attribute would not be set. This
differed from the behaviour in an executable jar/war where the exception
would be the one thrown by the application, and the request_uri
attribute would be set.

This commit updates ErrorPageFilter, which is only involved in a servlet
container, to unwrap a NestedServletException so that it’s the
application’s exception that’s handled, and to set the request_uri
attribute in the event of an exception being thrown or an error being
sent.

Closes gh-3249
2015-06-22 16:27:00 +01:00
Andy Wilkinson
d3d713d0c9 Merge branch '1.2.x' 2015-06-22 15:30:15 +01:00
olivier bourgain
5ed2a9632b Make InMemoryTraceRepository thread-safe
Closes gh-3027
2015-06-22 15:30:00 +01:00
Andy Wilkinson
24ef2e506b Merge branch '1.2.x' 2015-06-22 15:24:10 +01:00
Andy Wilkinson
8681a8ad2a Map empty virtual host to "/" when parsed from an address
Previously, an address that ended in a "/" would result in the virtual
host being an empty string. This was inconsistent with setVirtualHost
which would map an empty string to "/".

This commit updates the address parsing logic to call setVirtualHost
rather than assigning the value directly to this.virtualHost. This
ensures that the special handling for an empty string is applied
consistently.

Closes gh-3304
2015-06-22 15:20:41 +01:00
Andy Wilkinson
074771ec12 Merge branch '1.2.x' 2015-06-22 14:10:35 +01:00
Andy Wilkinson
cd62596e82 Provide default for SpringApplication main class in servlet container
By default, SpringApplication attempts to deduce the application class
by looking for a main method in the stack. This does not work when
the application is launched by a servlet container via
SpringBootServletInitializer as there's either no main method in the
stack, or the main method is that of the servlet container, rather
than the application.

This commit updates SpringBootServletInitializer to configure the
main class of the SpringApplication that it creates to be the
application's SpringBootServletInitializer subclass. This is done
prior to calling configure, so the main class can still be specified
by the application if required.

Closes gh-3061
2015-06-22 14:07:40 +01:00
Andy Wilkinson
d30dd1fa98 Merge branch '1.2.x' 2015-06-22 13:44:42 +01:00
Andy Wilkinson
01ba0f7571 Make RemoteIpValve's protocolHeaderHttpsValue configurable via the env
Closes gh-3289
2015-06-22 13:44:09 +01:00