Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expand English contractions from the documentation #28064

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -872,7 +872,7 @@ Data source instrumentation results in gauges that represent the currently activ

Metrics are also tagged by the name of the `DataSource` computed based on the bean name.

TIP: By default, Spring Boot provides metadata for all supported data sources.
TIP: By default, Spring Boot provides metadata for all supported data sources.
You can add additional `DataSourcePoolMetadataProvider` beans if your favorite data source is not supported.
See `DataSourcePoolMetadataProvidersConfiguration` for examples.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ Available commands:
----

The `extract` command can be used to easily split the application into layers to be added to the dockerfile.
Here's an example of a Dockerfile using `jarmode`.
Here is an example of a Dockerfile using `jarmode`.

[source,dockerfile,indent=0,subs="verbatim"]
----
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ One way to run an unpacked archive is by starting the appropriate launcher, as f
----

This is actually slightly faster on startup (depending on the size of the jar) than running from an unexploded archive.
At runtime you shouldn't expect any differences.
At runtime you should not expect any differences.

Once you have unpacked the jar file, you can also get an extra boost to startup time by running the app with its "natural" main method instead of the `JarLauncher`. For example:

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ TIP: If you do not use Spring Data MongoDB, you can inject a `MongoClient` bean
If you want to take complete control of establishing the MongoDB connection, you can also declare your own `MongoDatabaseFactory` or `MongoClient` bean.

NOTE: If you are using the reactive driver, Netty is required for SSL.
The auto-configuration configures this factory automatically if Netty is available and the factory to use hasn't been customized already.
The auto-configuration configures this factory automatically if Netty is available and the factory to use has not been customized already.



Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ Once the pre-stop hook has completed, SIGTERM will be sent to the container and

NOTE: When Kubernetes sends a SIGTERM signal to the pod, it waits for a specified time called the termination grace period (the default for which is 30 seconds).
If the containers are still running after the grace period, they are sent the SIGKILL signal and forcibly removed.
If the pod takes longer than 30 seconds to shut down, which could be because you've increased configprop:spring.lifecycle.timeout-per-shutdown-phase[], make sure to increase the termination grace period by setting the `terminationGracePeriodSeconds` option in the Pod YAML.
If the pod takes longer than 30 seconds to shut down, which could be because you have increased configprop:spring.lifecycle.timeout-per-shutdown-phase[], make sure to increase the termination grace period by setting the `terminationGracePeriodSeconds` option in the Pod YAML.



Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ Firstly, configure its permissions so that it cannot be written and can only be
$ chmod 500 your-app.jar
----

Second, you should also take steps to limit the damage if your application or the account that's running it is compromised.
Second, you should also take steps to limit the damage if your application or the account that is running it is compromised.
If an attacker does gain access, they could make the jar file writable and change its contents.
One way to protect against this is to make it immutable by using `chattr`, as shown in the following example:

Expand Down Expand Up @@ -286,7 +286,7 @@ The following property substitutions are supported with the default script:
|

| `useStartStopDaemon`
| Whether the `start-stop-daemon` command, when it's available, should be used to control the process
| Whether the `start-stop-daemon` command, when it is available, should be used to control the process
| `true`
| `true`

Expand Down Expand Up @@ -319,7 +319,7 @@ The following environment properties are supported with the default script:
When not set, the user that owns the jar file will be used.

| `USE_START_STOP_DAEMON`
| Whether the `start-stop-daemon` command, when it's available, should be used to control the process.
| Whether the `start-stop-daemon` command, when it is available, should be used to control the process.
Defaults to `true`.

| `PID_FOLDER`
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ The only difference between using these conditions at the class level and markin

TIP: When declaring a `@Bean` method, provide as much type information as possible in the method's return type.
For example, if your bean's concrete class implements an interface the bean method's return type should be the concrete class and not the interface.
Providing as much type information as possible in `@Bean` methods is particularly important when using bean conditions as their evaluation can only rely upon to type information that's available in the method signature.
Providing as much type information as possible in `@Bean` methods is particularly important when using bean conditions as their evaluation can only rely upon to type information that is available in the method signature.



Expand Down Expand Up @@ -209,7 +209,7 @@ include::{docs-java}/features/developingautoconfiguration/testing/MyServiceAutoC

[[features.developing-auto-configuration.custom-starter]]
=== Creating Your Own Starter
A typical Spring Boot starter contains code to auto-configure and customize the infrastructure of a given technology, let's call that "acme".
A typical Spring Boot starter contains code to auto-configure and customize the infrastructure of a given technology, let us call that "acme".
To make it easily extensible, a number of configuration keys in a dedicated namespace can be exposed to the environment.
Finally, a single "starter" dependency is provided to help users get started as easily as possible.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ The following example shows how to specify two distinct files:
optional:classpath:/override.properties
----

TIP: Use the prefix `optional:` if the <<features#features.external-config.files.optional-prefix,locations are optional>> and you don't mind if they don't exist.
TIP: Use the prefix `optional:` if the <<features#features.external-config.files.optional-prefix,locations are optional>> and you do not mind if they do not exist.

WARNING: `spring.config.name`, `spring.config.location`, and `spring.config.additional-location` are used very early to determine which files have to be loaded.
They must be defined as an environment property (typically an OS environment variable, a system property, or a command-line argument).
Expand Down Expand Up @@ -186,7 +186,7 @@ NOTE: If your application runs in a servlet container or application server, the
==== Optional Locations
By default, when a specified config data location does not exist, Spring Boot will throw a `ConfigDataLocationNotFoundException` and your application will not start.

If you want to specify a location, but you don't mind if it doesn't always exist, you can use the `optional:` prefix.
If you want to specify a location, but you do not mind if it does not always exist, you can use the `optional:` prefix.
You can use this prefix with the `spring.config.location` and `spring.config.additional-location` properties, as well as with <<features#features.external-config.files.importing, `spring.config.import`>> declarations.

For example, a `spring.config.import` value of `optional:file:./myconfig.properties` allows your application to start, even if the `myconfig.properties` file is missing.
Expand Down Expand Up @@ -261,7 +261,7 @@ The `Environment` has a set of default profiles (by default, `[default]`) that a
In other words, if no profiles are explicitly activated, then properties from `application-default` are considered.

NOTE: Properties files are only ever loaded once.
If you've already directly <<features#features.external-config.files.importing,imported>> a profile specific property files then it won't be imported a second time.
If you have already directly <<features#features.external-config.files.importing,imported>> a profile specific property files then it will not be imported a second time.



Expand All @@ -286,7 +286,7 @@ Values from the imported `dev.properties` will take precedence over the file tha
In the above example, the `dev.properties` could redefine `spring.application.name` to a different value.

An import will only be imported once no matter how many times it is declared.
The order an import is defined inside a single document within the properties/yaml file doesn't matter.
The order an import is defined inside a single document within the properties/yaml file does not matter.
For instance, the two examples below produce the same result:

[source,yaml,indent=0,subs="verbatim",configblocks]
Expand Down Expand Up @@ -320,7 +320,7 @@ The example above would import both `my.properties` as well as any `my-<profile>
Spring Boot includes pluggable API that allows various different location addresses to be supported.
By default you can import Java Properties, YAML and "`<<features#features.external-config.files.configtree, configuration trees>>`".

Third-party jars can offer support for additional technologies (there's no requirement for files to be local).
Third-party jars can offer support for additional technologies (there is no requirement for files to be local).
For example, you can imagine config data being from external stores such as Consul, Apache ZooKeeper or Netflix Archaius.

If you want to support your own locations, see the `ConfigDataLocationResolver` and `ConfigDataLoader` classes in the `org.springframework.boot.context.config` package.
Expand Down Expand Up @@ -349,7 +349,7 @@ You can import it from your `application.properties` using the following:
[[features.external-config.files.configtree]]
==== Using Configuration Trees
When running applications on a cloud platform (such as Kubernetes) you often need to read config values that the platform supplies.
It's not uncommon to use environment variables for such purposes, but this can have drawbacks, especially if the value is supposed to be kept secret.
It is not uncommon to use environment variables for such purposes, but this can have drawbacks, especially if the value is supposed to be kept secret.

As an alternative to environment variables, many cloud platforms now allow you to map configuration into mounted data volumes.
For example, Kubernetes can volume mount both https://kubernetes.io/docs/tasks/configure-pod-container/configure-pod-configmap/#populate-a-volume-with-data-stored-in-a-configmap[`ConfigMaps`] and https://kubernetes.io/docs/concepts/configuration/secret/#using-secrets-as-files-from-a-pod[`Secrets`].
Expand Down Expand Up @@ -495,7 +495,7 @@ WARNING: Multi-document property files cannot be loaded by using the `@PropertyS

[[features.external-config.files.activation-properties]]
==== Activation Properties
It's sometimes useful to only activate a given get of properties when certain conditions are met.
It is sometimes useful to only activate a given get of properties when certain conditions are met.
For example, you might have properties that are only relevant when a specific profile is active.

You can conditionally activate a properties document using `spring.config.activate.*`.
Expand Down Expand Up @@ -903,7 +903,7 @@ For example, consider binding the following properties to a `Map<String,String>`
NOTE: For YAML files, the brackets need to be surrounded by quotes for the keys to be parsed properly.

The properties above will bind to a `Map` with `/key1`, `/key2` and `key3` as the keys in the map.
The slash has been removed from `key3` because it wasn't surrounded by square brackets.
The slash has been removed from `key3` because it was not surrounded by square brackets.

You may also occasionally need to use the bracket notation if your `key` contains a `.` and you are binding to non-scalar value.
For example, binding `a.b=c` to `Map<String, Object>` will return a Map with the entry `{"a"={"b"="c"}}` whereas `[a.b]=c` will return a Map with the entry `{"a.b"="c"}`.
Expand Down Expand Up @@ -1081,7 +1081,7 @@ include::{docs-java}/features/externalconfig/typesafeconfigurationproperties/con
----


TIP: If you are upgrading a `Long` property, make sure to define the unit (using `@DurationUnit`) if it isn't milliseconds.
TIP: If you are upgrading a `Long` property, make sure to define the unit (using `@DurationUnit`) if it is not milliseconds.
Doing so gives a transparent upgrade path while supporting a much richer format.


Expand Down Expand Up @@ -1142,7 +1142,7 @@ If you prefer to use constructor binding, the same properties can be exposed, as
include::{docs-java}/features/externalconfig/typesafeconfigurationproperties/conversion/datasizes/constructorbinding/MyProperties.java[]
----

TIP: If you are upgrading a `Long` property, make sure to define the unit (using `@DataSizeUnit`) if it isn't bytes.
TIP: If you are upgrading a `Long` property, make sure to define the unit (using `@DataSizeUnit`) if it is not bytes.
Doing so gives a transparent upgrade path while supporting a much richer format.


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ Spring Boot first attempts to create a client by checking the following configur
NOTE: Spring Boot supports both Hazelcast 4 and Hazelcast 3.
If you downgrade to Hazelcast 3, `hazelcast-client` should be added to the classpath to configure a client.

If a client can't be created, Spring Boot attempts to configure an embedded server.
If a client can not be created, Spring Boot attempts to configure an embedded server.
If you define a `com.hazelcast.config.Config` bean, Spring Boot uses that.
If your configuration defines an instance name, Spring Boot tries to locate an existing instance rather than creating a new one.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -161,8 +161,8 @@ As a result, specific configuration keys (such as `logback.configurationFile` fo

[[features.logging.file-rotation]]
=== File Rotation
If you are using the Logback, it's possible to fine-tune log rotation settings using your `application.properties` or `application.yaml` file.
For all other logging system, you'll need to configure rotation settings directly yourself (for example, if you use Log4J2 then you could add a `log4j.xml` file).
If you are using the Logback, it is possible to fine-tune log rotation settings using your `application.properties` or `application.yaml` file.
For all other logging system, you will need to configure rotation settings directly yourself (for example, if you use Log4J2 then you could add a `log4j.xml` file).

The following rotation policy properties are supported:

Expand All @@ -176,7 +176,7 @@ The following rotation policy properties are supported:
| If log archive cleanup should occur when the application starts.

| configprop:logging.logback.rollingpolicy.max-file-size[]
| The maximum size of log file before it's archived.
| The maximum size of log file before it is archived.

| configprop:logging.logback.rollingpolicy.total-size-cap[]
| The maximum amount of size log archives can take before being deleted.
Expand Down Expand Up @@ -212,22 +212,22 @@ The following example shows potential logging settings in `application.propertie
org.hibernate: "error"
----

It's also possible to set logging levels using environment variables.
It is also possible to set logging levels using environment variables.
For example, `LOGGING_LEVEL_ORG_SPRINGFRAMEWORK_WEB=DEBUG` will set `org.springframework.web` to `DEBUG`.

NOTE: The above approach will only work for package level logging.
Since relaxed binding always converts environment variables to lowercase, it's not possible to configure logging for an individual class in this way.
Since relaxed binding always converts environment variables to lowercase, it is not possible to configure logging for an individual class in this way.
If you need to configure logging for a class, you can use <<features#features.external-config.application-json, the `SPRING_APPLICATION_JSON`>> variable.



[[features.logging.log-groups]]
=== Log Groups
It's often useful to be able to group related loggers together so that they can all be configured at the same time.
For example, you might commonly change the logging levels for _all_ Tomcat related loggers, but you can't easily remember top level packages.
It is often useful to be able to group related loggers together so that they can all be configured at the same time.
For example, you might commonly change the logging levels for _all_ Tomcat related loggers, but you can not easily remember top level packages.

To help with this, Spring Boot allows you to define logging groups in your Spring `Environment`.
For example, here's how you could define a "`tomcat`" group by adding it to your `application.properties`:
For example, here is how you could define a "`tomcat`" group by adding it to your `application.properties`:

[source,yaml,indent=0,subs="verbatim",configprops,configblocks]
----
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ For instance, if you start a web application on port `8080` and that port is alr

Action:

Identify and stop the process that's listening on port 8080 or configure this application to listen on another port.
Identify and stop the process that is listening on port 8080 or configure this application to listen on another port.
----

NOTE: Spring Boot provides numerous `FailureAnalyzer` implementations, and you can <<howto#howto.application.failure-analyzer,add your own>>.
Expand Down Expand Up @@ -152,7 +152,7 @@ The printed banner is registered as a singleton bean under the following name: `
[NOTE]
====
The `${application.version}` and `${application.formatted-version}` properties are only available if you are using Spring Boot launchers.
The values won't be resolved if you are running an unpacked jar and starting it with `java -cp <classpath> <mainclass>`.
The values will not be resolved if you are running an unpacked jar and starting it with `java -cp <classpath> <mainclass>`.

This is why we recommend that you always launch unpacked jars using `java org.springframework.boot.loader.JarLauncher`.
This will initialize the `application.*` banner variables before building the classpath and launching your app.
Expand Down Expand Up @@ -209,7 +209,7 @@ In addition, you can also obtain availability states by injecting the `Applicati

[[features.spring-application.application-availability.liveness]]
==== Liveness State
The "`Liveness`" state of an application tells whether its internal state allows it to work correctly, or recover by itself if it's currently failing.
The "`Liveness`" state of an application tells whether its internal state allows it to work correctly, or recover by itself if it is currently failing.
A broken "`Liveness`" state means that the application is in a state that it cannot recover from, and the infrastructure should restart the application.

NOTE: In general, the "Liveness" state should not be based on external checks, such as <<actuator#actuator.endpoints.health, Health checks>>.
Expand All @@ -225,7 +225,7 @@ An application is considered live as soon as the context has been refreshed, see
==== Readiness State
The "`Readiness`" state of an application tells whether the application is ready to handle traffic.
A failing "`Readiness`" state tells the platform that it should not route traffic to the application for now.
This typically happens during startup, while `CommandLineRunner` and `ApplicationRunner` components are being processed, or at any time if the application decides that it's too busy for additional traffic.
This typically happens during startup, while `CommandLineRunner` and `ApplicationRunner` components are being processed, or at any time if the application decides that it is too busy for additional traffic.

An application is considered ready as soon as application and command-line runners have been called, see <<features#features.spring-application.application-events-and-listeners, Spring Boot application lifecycle and related Application Events>>.

Expand Down