Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in / Register
Toggle navigation
S
spring-boot
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
DEMO
spring-boot
Commits
0a4daf0d
Commit
0a4daf0d
authored
Feb 25, 2015
by
Phillip Webb
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #2553 from izeye/docs
* docs: Improve documentation
parents
2a87971f
1493da1e
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
23 additions
and
22 deletions
+23
-22
appendix-application-properties.adoc
...cs/src/main/asciidoc/appendix-application-properties.adoc
+1
-0
howto.adoc
spring-boot-docs/src/main/asciidoc/howto.adoc
+1
-1
production-ready-features.adoc
...oot-docs/src/main/asciidoc/production-ready-features.adoc
+1
-1
spring-boot-features.adoc
spring-boot-docs/src/main/asciidoc/spring-boot-features.adoc
+11
-11
using-spring-boot.adoc
spring-boot-docs/src/main/asciidoc/using-spring-boot.adoc
+9
-9
No files found.
spring-boot-docs/src/main/asciidoc/appendix-application-properties.adoc
View file @
0a4daf0d
...
@@ -96,6 +96,7 @@ content into your application; rather pick only the properties that you need.
...
@@ -96,6 +96,7 @@ content into your application; rather pick only the properties that you need.
spring.mvc.ignore-default-model-on-redirect=true # If the the content of the "default" model should be ignored redirects
spring.mvc.ignore-default-model-on-redirect=true # If the the content of the "default" model should be ignored redirects
spring.view.prefix= # MVC view prefix
spring.view.prefix= # MVC view prefix
spring.view.suffix= # ... and suffix
spring.view.suffix= # ... and suffix
spring.favicon.enabled=true
# SPRING RESOURCES HANDLING ({sc-spring-boot-autoconfigure}/web/ResourceProperties.{sc-ext}[ResourceProperties])
# SPRING RESOURCES HANDLING ({sc-spring-boot-autoconfigure}/web/ResourceProperties.{sc-ext}[ResourceProperties])
spring.resources.cache-period= # cache timeouts in headers sent to browser
spring.resources.cache-period= # cache timeouts in headers sent to browser
...
...
spring-boot-docs/src/main/asciidoc/howto.adoc
View file @
0a4daf0d
...
@@ -344,7 +344,7 @@ and mark it as disabled. For example:
...
@@ -344,7 +344,7 @@ and mark it as disabled. For example:
[source,java,indent=0,subs="verbatim,quotes,attributes"]
[source,java,indent=0,subs="verbatim,quotes,attributes"]
----
----
Bean
@
Bean
public FilterRegistrationBean registration(MyFilter filter) {
public FilterRegistrationBean registration(MyFilter filter) {
FilterRegistrationBean registration = new FilterRegistrationBean(filter);
FilterRegistrationBean registration = new FilterRegistrationBean(filter);
registration.setEnabled(false);
registration.setEnabled(false);
...
...
spring-boot-docs/src/main/asciidoc/production-ready-features.adoc
View file @
0a4daf0d
...
@@ -12,7 +12,7 @@ Auditing, health and metrics gathering can be automatically applied to your appl
...
@@ -12,7 +12,7 @@ Auditing, health and metrics gathering can be automatically applied to your appl
[[production-ready-enabling]]
[[production-ready-enabling]]
== Enabling production-ready features
.
== Enabling production-ready features
The {github-code}/spring-boot-actuator[`spring-boot-actuator`] module provides all of
The {github-code}/spring-boot-actuator[`spring-boot-actuator`] module provides all of
Spring Boot'
s
production
-
ready
features
.
The
simplest
way
to
enable
the
features
is
to
add
Spring Boot'
s
production
-
ready
features
.
The
simplest
way
to
enable
the
features
is
to
add
a
dependency
to
the
`
spring
-
boot
-
starter
-
actuator
`
'`Starter POM`'
.
a
dependency
to
the
`
spring
-
boot
-
starter
-
actuator
`
'`Starter POM`'
.
...
...
spring-boot-docs/src/main/asciidoc/spring-boot-features.adoc
View file @
0a4daf0d
...
@@ -901,7 +901,7 @@ Depending on your logging system, the following files will be loaded:
...
@@ -901,7 +901,7 @@ Depending on your logging system, the following files will be loaded:
|Logging System |Customization
|Logging System |Customization
|Logback
|Logback
|`logback.xml`
|`logback.xml`
or `logback.groovy`
|Log4j
|Log4j
|`log4j.properties` or `log4j.xml`
|`log4j.properties` or `log4j.xml`
...
@@ -936,7 +936,7 @@ To help with the customization some other properties are transferred from the Sp
...
@@ -936,7 +936,7 @@ To help with the customization some other properties are transferred from the Sp
All the logging systems supported can consult System properties when parsing their
All the logging systems supported can consult System properties when parsing their
configuration files. See the default configurations in `spring-boot.jar` for examples.
configuration files. See the default configurations in `spring-boot.jar` for examples.
WARNING: There are know classloading issues with Java Util Logging that cause problems
WARNING: There are know
n
classloading issues with Java Util Logging that cause problems
when running from an '`executable jar`'. We recommend that you avoid it if at all
when running from an '`executable jar`'. We recommend that you avoid it if at all
possible.
possible.
...
@@ -1004,7 +1004,7 @@ The auto-configuration adds the following features on top of Spring's defaults:
...
@@ -1004,7 +1004,7 @@ The auto-configuration adds the following features on top of Spring's defaults:
* Support for serving static resources, including support for WebJars (see below).
* Support for serving static resources, including support for WebJars (see below).
* Automatic registration of `Converter`, `GenericConverter`, `Formatter` beans.
* Automatic registration of `Converter`, `GenericConverter`, `Formatter` beans.
* Support for `HttpMessageConverters` (see below).
* Support for `HttpMessageConverters` (see below).
* Automatic registration of `MessageCode
Resolver` (see below)
* Automatic registration of `MessageCode
sResolver` (see below).
* Static `index.html` support.
* Static `index.html` support.
* Custom `Favicon` support.
* Custom `Favicon` support.
...
@@ -1358,7 +1358,7 @@ If the above customization techniques are too limited, you can register the
...
@@ -1358,7 +1358,7 @@ If the above customization techniques are too limited, you can register the
TomcatEmbeddedServletContainerFactory factory = new TomcatEmbeddedServletContainerFactory();
TomcatEmbeddedServletContainerFactory factory = new TomcatEmbeddedServletContainerFactory();
factory.setPort(9000);
factory.setPort(9000);
factory.setSessionTimeout(10, TimeUnit.MINUTES);
factory.setSessionTimeout(10, TimeUnit.MINUTES);
factory.addErrorPages(new ErrorPage(HttpStatus.NOT_FOUND, "/notfound.html");
factory.addErrorPages(new ErrorPage(HttpStatus.NOT_FOUND, "/notfound.html")
)
;
return factory;
return factory;
}
}
----
----
...
@@ -1516,9 +1516,9 @@ Production database connections can also be auto-configured using a pooling
...
@@ -1516,9 +1516,9 @@ Production database connections can also be auto-configured using a pooling
* We prefer the Tomcat pooling `DataSource` for its performance and concurrency, so if
* We prefer the Tomcat pooling `DataSource` for its performance and concurrency, so if
that is available we always choose it.
that is available we always choose it.
* If HikariCP is available we will use it
* If HikariCP is available we will use it
.
* If Commons DBCP is available we will use it, but we don't recommend it in production.
* If Commons DBCP is available we will use it, but we don't recommend it in production.
* Lastly, if Commons DBCP2 is available we will use it
* Lastly, if Commons DBCP2 is available we will use it
.
If you use the `spring-boot-starter-jdbc` or `spring-boot-starter-data-jpa`
If you use the `spring-boot-starter-jdbc` or `spring-boot-starter-data-jpa`
'`starter POMs`' you will automatically get a dependency to `tomcat-jdbc`.
'`starter POMs`' you will automatically get a dependency to `tomcat-jdbc`.
...
@@ -1607,7 +1607,7 @@ relational databases. The `spring-boot-starter-data-jpa` POM provides a quick wa
...
@@ -1607,7 +1607,7 @@ relational databases. The `spring-boot-starter-data-jpa` POM provides a quick wa
started. It provides the following key dependencies:
started. It provides the following key dependencies:
* Hibernate -- One of the most popular JPA implementations.
* Hibernate -- One of the most popular JPA implementations.
* Spring Data JPA -- Makes it easy to
easily
implement JPA-based repositories.
* Spring Data JPA -- Makes it easy to implement JPA-based repositories.
* Spring ORMs -- Core ORM support from the Spring Framework.
* Spring ORMs -- Core ORM support from the Spring Framework.
TIP: We won't go into too many details of JPA or Spring Data here. You can follow the
TIP: We won't go into too many details of JPA or Spring Data here. You can follow the
...
@@ -1812,7 +1812,7 @@ pooled connection factory by default.
...
@@ -1812,7 +1812,7 @@ pooled connection factory by default.
=== MongoDB
=== MongoDB
http://www.mongodb.com/[MongoDB] is an open-source NoSQL document database that uses a
http://www.mongodb.com/[MongoDB] is an open-source NoSQL document database that uses a
JSON-like schema instead of traditional table-based relational data. Spring Boot offers
JSON-like schema instead of traditional table-based relational data. Spring Boot offers
several conveniences for working with MongoDB, including the
The
several conveniences for working with MongoDB, including the
`spring-boot-starter-data-mongodb` '`Starter POM`'.
`spring-boot-starter-data-mongodb` '`Starter POM`'.
...
@@ -1826,7 +1826,7 @@ using the URL `mongodb://localhost/test`:
...
@@ -1826,7 +1826,7 @@ using the URL `mongodb://localhost/test`:
[source,java,indent=0]
[source,java,indent=0]
----
----
import org.springframework.data.mongodb.MongoDbFactory;
import org.springframework.data.mongodb.MongoDbFactory;
import
import
com.mongodb.DB;
import com.mongodb.DB;
@Component
@Component
public class MyBean {
public class MyBean {
...
@@ -1864,7 +1864,7 @@ could simply delete this line from the sample above.
...
@@ -1864,7 +1864,7 @@ could simply delete this line from the sample above.
TIP: If you aren't using Spring Data Mongo you can inject `com.mongodb.Mongo` beans
TIP: If you aren't using Spring Data Mongo you can inject `com.mongodb.Mongo` beans
instead of using `MongoDbFactory`.
instead of using `MongoDbFactory`.
You can also declare your own `MongoDbFactory` or `Mongo`
`@Beans`
if you want to take
You can also declare your own `MongoDbFactory` or `Mongo`
bean
if you want to take
complete control of establishing the MongoDB connection.
complete control of establishing the MongoDB connection.
...
@@ -2084,7 +2084,7 @@ available on the classpath. If the broker is present, an embedded broker is star
...
@@ -2084,7 +2084,7 @@ available on the classpath. If the broker is present, an embedded broker is star
configured automatically (unless the mode property has been explicitly set). The supported
configured automatically (unless the mode property has been explicitly set). The supported
modes are: `embedded` (to make explicit that an embedded broker is required and should
modes are: `embedded` (to make explicit that an embedded broker is required and should
lead to an error if the broker is not available in the classpath), and `native` to
lead to an error if the broker is not available in the classpath), and `native` to
connect to a broker using the
the
`netty` transport protocol. When the latter is
connect to a broker using the `netty` transport protocol. When the latter is
configured, Spring Boot configures a `ConnectionFactory` connecting to a broker running
configured, Spring Boot configures a `ConnectionFactory` connecting to a broker running
on the local machine with the default settings.
on the local machine with the default settings.
...
...
spring-boot-docs/src/main/asciidoc/using-spring-boot.adoc
View file @
0a4daf0d
...
@@ -44,7 +44,7 @@ defaults. The parent project provides the following features:
...
@@ -44,7 +44,7 @@ defaults. The parent project provides the following features:
http://maven.apache.org/plugins/maven-shade-plugin/[shade]).
http://maven.apache.org/plugins/maven-shade-plugin/[shade]).
* Sensible resource filtering for `application.properties` and `application.yml`
* Sensible resource filtering for `application.properties` and `application.yml`
On the last point: since the default config files
files
accept
On the last point: since the default config files accept
Spring style placeholders (`${...}`) the Maven filtering is changed to
Spring style placeholders (`${...}`) the Maven filtering is changed to
use `@..@` placeholders (you can override that with a Maven property
use `@..@` placeholders (you can override that with a Maven property
`resource.delimiter`).
`resource.delimiter`).
...
@@ -259,10 +259,10 @@ and Hibernate.
...
@@ -259,10 +259,10 @@ and Hibernate.
|Support for the Apache Solr search platform, including `spring-data-solr`.
|Support for the Apache Solr search platform, including `spring-data-solr`.
|`spring-boot-starter-freemarker`
|`spring-boot-starter-freemarker`
|Support for the FreeMarker templating engine
|Support for the FreeMarker templating engine
.
|`spring-boot-starter-groovy-templates`
|`spring-boot-starter-groovy-templates`
|Support for the Groovy templating engine
|Support for the Groovy templating engine
.
|`spring-boot-starter-hateoas`
|`spring-boot-starter-hateoas`
|Support for HATEOAS-based RESTful services via `spring-hateoas`.
|Support for HATEOAS-based RESTful services via `spring-hateoas`.
...
@@ -289,7 +289,7 @@ and Hibernate.
...
@@ -289,7 +289,7 @@ and Hibernate.
|Support for `javax.mail`.
|Support for `javax.mail`.
|`spring-boot-starter-mobile`
|`spring-boot-starter-mobile`
|Support for `spring-mobile`
|Support for `spring-mobile`
.
|`spring-boot-starter-mustache`
|`spring-boot-starter-mustache`
|Support for the Mustache templating engine.
|Support for the Mustache templating engine.
...
@@ -317,7 +317,7 @@ and Hibernate.
...
@@ -317,7 +317,7 @@ and Hibernate.
|Support for the Thymeleaf templating engine, including integration with Spring.
|Support for the Thymeleaf templating engine, including integration with Spring.
|`spring-boot-starter-velocity`
|`spring-boot-starter-velocity`
|Support for the Velocity templating engine
|Support for the Velocity templating engine
.
|`spring-boot-starter-web`
|`spring-boot-starter-web`
|Support for full-stack web development, including Tomcat and `spring-webmvc`.
|Support for full-stack web development, including Tomcat and `spring-webmvc`.
...
@@ -326,7 +326,7 @@ and Hibernate.
...
@@ -326,7 +326,7 @@ and Hibernate.
|Support for WebSocket development.
|Support for WebSocket development.
|`spring-boot-starter-ws`
|`spring-boot-starter-ws`
|Support for Spring Web Services
|Support for Spring Web Services
.
|===
|===
In addition to the application starters, the following starters can be used to
In addition to the application starters, the following starters can be used to
...
@@ -351,10 +351,10 @@ swap specific technical facets.
...
@@ -351,10 +351,10 @@ swap specific technical facets.
| Name | Description
| Name | Description
|`spring-boot-starter-jetty`
|`spring-boot-starter-jetty`
|Imports the Jetty HTTP engine (to be used as an alternative to Tomcat)
|Imports the Jetty HTTP engine (to be used as an alternative to Tomcat)
.
|`spring-boot-starter-log4j`
|`spring-boot-starter-log4j`
|Support the Log4J logging framework
|Support the Log4J logging framework
.
|`spring-boot-starter-logging`
|`spring-boot-starter-logging`
|Import Spring Boot'
s
default
logging
framework
(
Logback
).
|Import Spring Boot'
s
default
logging
framework
(
Logback
).
...
@@ -363,7 +363,7 @@ swap specific technical facets.
...
@@ -363,7 +363,7 @@ swap specific technical facets.
|
Import
Spring
Boot
's default HTTP engine (Tomcat).
|
Import
Spring
Boot
's default HTTP engine (Tomcat).
|`spring-boot-starter-undertow`
|`spring-boot-starter-undertow`
|Imports the Undertow HTTP engine (to be used as an alternative to Tomcat)
|Imports the Undertow HTTP engine (to be used as an alternative to Tomcat)
.
|===
|===
TIP: For a list of additional community contributed starter POMs, see the
TIP: For a list of additional community contributed starter POMs, see the
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment