From 2ad3428039e12af39db9991cf421e3df60d2498a Mon Sep 17 00:00:00 2001 From: Dmitriy Bogdanov Date: Mon, 13 Sep 2021 13:52:28 +0400 Subject: [PATCH 1/2] Fix some typos in docs See gh-27968 --- .../src/docs/asciidoc/documentation/data.adoc | 2 +- .../src/docs/asciidoc/features/external-config.adoc | 8 ++++---- .../src/docs/asciidoc/using/devtools.adoc | 2 +- .../src/docs/asciidoc/using/running-your-application.adoc | 2 +- .../using/spring-beans-and-dependency-injection.adoc | 2 +- .../spring-boot-docs/src/docs/asciidoc/web/servlet.adoc | 2 +- 6 files changed, 9 insertions(+), 9 deletions(-) diff --git a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/documentation/data.adoc b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/documentation/data.adoc index 85e1a862ed..57799527fb 100644 --- a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/documentation/data.adoc +++ b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/documentation/data.adoc @@ -3,4 +3,4 @@ If your application deals with a datastore, you can see how to configure that here: * *SQL:* <> -* *NOSQL:* <> +* *NOSQL:* <> diff --git a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/external-config.adoc b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/external-config.adoc index 88e4c2290a..8615cc0eae 100644 --- a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/external-config.adoc +++ b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/external-config.adoc @@ -12,7 +12,7 @@ Properties are considered in the following order (with values from lower items o . {spring-framework-api}/context/annotation/PropertySource.html[`@PropertySource`] annotations on your `@Configuration` classes. Please note that such property sources are not added to the `Environment` until the application context is being refreshed. This is too late to configure certain properties such as `+logging.*+` and `+spring.main.*+` which are read before refresh begins. -. Config data (such as `application.properties` files) +. Config data (such as `application.properties` files). . A `RandomValuePropertySource` that has properties only in `+random.*+`. . OS environment variables. . Java System properties (`System.getProperties()`). @@ -56,7 +56,7 @@ See the "<>" section for [[features.external-config.command-line-args]] === Accessing Command Line Properties By default, `SpringApplication` converts any command line option arguments (that is, arguments starting with `--`, such as `--server.port=9000`) to a `property` and adds them to the Spring `Environment`. -As mentioned previously, command line properties always take precedence over file based property sources. +As mentioned previously, command line properties always take precedence over file-based property sources. If you do not want command line properties to be added to the `Environment`, you can disable them by using `SpringApplication.setAddCommandLineProperties(false)`. @@ -668,11 +668,11 @@ The preceding POJO defines the following properties: * `my.service.enabled`, with a value of `false` by default. * `my.service.remote-address`, with a type that can be coerced from `String`. * `my.service.security.username`, with a nested "security" object whose name is determined by the name of the property. - In particular, the return type is not used at all there and could have been `SecurityProperties`. + In particular, the type is not used at all there and could have been `SecurityProperties`. * `my.service.security.password`. * `my.service.security.roles`, with a collection of `String` that defaults to `USER`. -NOTE: The properties that map to `@ConfigurationProperties` classes available in Spring Boot, which are configured via properties files, YAML files, environment variables etc., are public API but the accessors (getters/setters) of the class itself are not meant to be used directly. +NOTE: The properties that map to `@ConfigurationProperties` classes available in Spring Boot, which are configured via properties files, YAML files, environment variables, etc., are public API but the accessors (getters/setters) of the class itself are not meant to be used directly. [NOTE] ==== diff --git a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/using/devtools.adoc b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/using/devtools.adoc index 4a4cb5e412..6d84d9b842 100644 --- a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/using/devtools.adoc +++ b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/using/devtools.adoc @@ -274,7 +274,7 @@ You can configure global devtools settings by adding any of the following files . `spring-boot-devtools.yaml` . `spring-boot-devtools.yml` -Any properties added to these file apply to _all_ Spring Boot applications on your machine that use devtools. +Any properties added to these files apply to _all_ Spring Boot applications on your machine that use devtools. For example, to configure restart to always use a <>, you would add the following property to your `spring-boot-devtools` file: [source,yaml,indent=0,subs="verbatim",configprops,configblocks] diff --git a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/using/running-your-application.adoc b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/using/running-your-application.adoc index 857c5cae6e..27ca9d405c 100644 --- a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/using/running-your-application.adoc +++ b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/using/running-your-application.adoc @@ -4,7 +4,7 @@ One of the biggest advantages of packaging your application as a jar and using a The sample applies to debugging Spring Boot applications. You do not need any special IDE plugins or extensions. -NOTE: This section only covers jar based packaging. +NOTE: This section only covers jar-based packaging. If you choose to package your application as a war file, you should refer to your server and IDE documentation. diff --git a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/using/spring-beans-and-dependency-injection.adoc b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/using/spring-beans-and-dependency-injection.adoc index 1c0347bba5..c76fbb8657 100644 --- a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/using/spring-beans-and-dependency-injection.adoc +++ b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/using/spring-beans-and-dependency-injection.adoc @@ -4,7 +4,7 @@ You are free to use any of the standard Spring Framework techniques to define yo We generally recommend using constructor injection to wire up dependencies and `@ComponentScan` to find beans. If you structure your code as suggested above (locating your application class in a top package), you can add `@ComponentScan` without any arguments or use the `@SpringBootApplication` annotation which implicitly includes it. -All of your application components (`@Component`, `@Service`, `@Repository`, `@Controller` etc.) are automatically registered as Spring Beans. +All of your application components (`@Component`, `@Service`, `@Repository`, `@Controller`, etc.) are automatically registered as Spring Beans. The following example shows a `@Service` Bean that uses constructor injection to obtain a required `RiskAssessor` bean: diff --git a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/web/servlet.adoc b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/web/servlet.adoc index 9c950c6d34..4e2cf1edef 100644 --- a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/web/servlet.adoc +++ b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/web/servlet.adoc @@ -443,7 +443,7 @@ To do so, set the `spring.security.filter.dispatcher-types` property to `async, [[web.servlet.spring-mvc.cors]] ==== CORS Support -https://en.wikipedia.org/wiki/Cross-origin_resource_sharing[Cross-origin resource sharing] (CORS) is a https://www.w3.org/TR/cors/[W3C specification] implemented by https://caniuse.com/#feat=cors[most browsers] that lets you specify in a flexible way what kind of cross-domain requests are authorized., instead of using some less secure and less powerful approaches such as IFRAME or JSONP. +https://en.wikipedia.org/wiki/Cross-origin_resource_sharing[Cross-origin resource sharing] (CORS) is a https://www.w3.org/TR/cors/[W3C specification] implemented by https://caniuse.com/#feat=cors[most browsers] that lets you specify in a flexible way what kind of cross-domain requests are authorized, instead of using some less secure and less powerful approaches such as IFRAME or JSONP. As of version 4.2, Spring MVC {spring-framework-docs}/web.html#mvc-cors[supports CORS]. Using {spring-framework-docs}/web.html#mvc-cors-controller[controller method CORS configuration] with {spring-framework-api}/web/bind/annotation/CrossOrigin.html[`@CrossOrigin`] annotations in your Spring Boot application does not require any specific configuration. From c4823f80cdf0783938df8afd6f5ea301caca614b Mon Sep 17 00:00:00 2001 From: Stephane Nicoll Date: Tue, 14 Sep 2021 09:18:04 +0200 Subject: [PATCH 2/2] Polish "Fix some typos in docs" See gh-27968 --- .../spring-boot-docs/src/docs/asciidoc/documentation/data.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/documentation/data.adoc b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/documentation/data.adoc index 57799527fb..e72b9a2b5f 100644 --- a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/documentation/data.adoc +++ b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/documentation/data.adoc @@ -2,5 +2,5 @@ == Data If your application deals with a datastore, you can see how to configure that here: -* *SQL:* <> +* *SQL:* <> * *NOSQL:* <>