You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: spring-boot-project/spring-boot-docs/src/docs/antora/modules/how-to/pages/actuator.adoc
+2-2
Original file line number
Diff line number
Diff line change
@@ -21,7 +21,7 @@ For more detail, see the javadoc:org.springframework.boot.actuate.autoconfigure.
21
21
== Customizing Sanitization
22
22
23
23
To take control over the sanitization, define a `SanitizingFunction` bean.
24
-
The `SanitizableData` with which the function is called provides access to the key and value as well as the `PropertySource` from which they came.
24
+
The `SanitizableData` with which the function is called provides access to the key and value as well as the `org.springframework.core.env.PropertySource` from which they came.
25
25
This allows you to, for example, sanitize every value that comes from a particular property source.
26
26
Each `SanitizingFunction` is called in order until a function changes the value of the sanitizable data.
27
27
@@ -30,7 +30,7 @@ Each `SanitizingFunction` is called in order until a function changes the value
Copy file name to clipboardExpand all lines: spring-boot-project/spring-boot-docs/src/docs/antora/modules/how-to/pages/batch.adoc
+5-5
Original file line number
Diff line number
Diff line change
@@ -42,10 +42,10 @@ If you do so and want two task executors (for example by retaining the auto-conf
42
42
43
43
Spring Batch auto-configuration is enabled by adding `spring-boot-starter-batch` to your application's classpath.
44
44
45
-
If a single `Job` bean is found in the application context, it is executed on startup (see javadoc:org.springframework.boot.autoconfigure.batch.JobLauncherApplicationRunner[] for details).
46
-
If multiple `Job` beans are found, the job that should be executed must be specified using configprop:spring.batch.job.name[].
45
+
If a single `org.springframework.batch.core.Job` bean is found in the application context, it is executed on startup (see javadoc:org.springframework.boot.autoconfigure.batch.JobLauncherApplicationRunner[] for details).
46
+
If multiple `org.springframework.batch.core.Job` beans are found, the job that should be executed must be specified using configprop:spring.batch.job.name[].
47
47
48
-
To disable running a `Job` found in the application context, set the configprop:spring.batch.job.enabled[] to `false`.
48
+
To disable running a `org.springframework.batch.core.Job` found in the application context, set the configprop:spring.batch.job.enabled[] to `false`.
49
49
50
50
See {code-spring-boot-autoconfigure-src}/batch/BatchAutoConfiguration.java[`BatchAutoConfiguration`] for more details.
51
51
@@ -78,7 +78,7 @@ This provides only one argument to the batch job: `someParameter=someValue`.
78
78
[[howto.batch.restarting-a-failed-job]]
79
79
== Restarting a Stopped or Failed Job
80
80
81
-
To restart a failed `Job`, all parameters (identifying and non-identifying) must be re-specified on the command line.
81
+
To restart a failed `org.springframework.batch.core.Job`, all parameters (identifying and non-identifying) must be re-specified on the command line.
82
82
Non-identifying parameters are *not* copied from the previous execution.
83
83
This allows them to be modified or removed.
84
84
@@ -89,6 +89,6 @@ NOTE: When you're using a custom `JobParametersIncrementer`, you have to gather
89
89
[[howto.batch.storing-job-repository]]
90
90
== Storing the Job Repository
91
91
92
-
Spring Batch requires a data store for the `Job` repository.
92
+
Spring Batch requires a data store for the `org.springframework.batch.core.Job` repository.
93
93
If you use Spring Boot, you must use an actual database.
94
94
Note that it can be an in-memory database, see {url-spring-batch-docs}/job.html#configuringJobRepository[Configuring a Job Repository].
Copy file name to clipboardExpand all lines: spring-boot-project/spring-boot-docs/src/docs/antora/modules/how-to/pages/build.adoc
+1-1
Original file line number
Diff line number
Diff line change
@@ -83,7 +83,7 @@ Both the Maven and Gradle plugins allow the properties that are included in `git
83
83
84
84
TIP: The commit time in `git.properties` is expected to match the following format: `yyyy-MM-dd'T'HH:mm:ssZ`.
85
85
This is the default format for both plugins listed above.
86
-
Using this format lets the time be parsed into a `Date` and its format, when serialized to JSON, to be controlled by Jackson's date serialization configuration settings.
86
+
Using this format lets the time be parsed into a `java.util.Date` and its format, when serialized to JSON, to be controlled by Jackson's date serialization configuration settings.
Copy file name to clipboardExpand all lines: spring-boot-project/spring-boot-docs/src/docs/antora/modules/how-to/pages/data-access.adoc
+9-9
Original file line number
Diff line number
Diff line change
@@ -158,14 +158,14 @@ See xref:reference:data/sql.adoc#data.sql.datasource.connection-pool[] for detai
158
158
[[howto.data-access.spring-data-repositories]]
159
159
== Use Spring Data Repositories
160
160
161
-
Spring Data can create implementations of `Repository` interfaces of various flavors.
162
-
Spring Boot handles all of that for you, as long as those `Repository` implementations are included in one of the xref:reference:using/auto-configuration.adoc#using.auto-configuration.packages[auto-configuration packages], typically the package (or a sub-package) of your main application class that is annotated with `@SpringBootApplication` or `@EnableAutoConfiguration`.
161
+
Spring Data can create implementations of `org.springframework.data.repository.Repository` interfaces of various flavors.
162
+
Spring Boot handles all of that for you, as long as those `org.springframework.data.repository.Repository` implementations are included in one of the xref:reference:using/auto-configuration.adoc#using.auto-configuration.packages[auto-configuration packages], typically the package (or a sub-package) of your main application class that is annotated with `@SpringBootApplication` or `@EnableAutoConfiguration`.
163
163
164
164
For many applications, all you need is to put the right Spring Data dependencies on your classpath.
165
165
There is a `spring-boot-starter-data-jpa` for JPA, `spring-boot-starter-data-mongodb` for Mongodb, and various other starters for supported technologies.
166
166
To get started, create some repository interfaces to handle your `@Entity` objects.
167
167
168
-
Spring Boot determines the location of your `Repository` implementations by scanning the xref:reference:using/auto-configuration.adoc#using.auto-configuration.packages[auto-configuration packages].
168
+
Spring Boot determines the location of your `org.springframework.data.repository.Repository` implementations by scanning the xref:reference:using/auto-configuration.adoc#using.auto-configuration.packages[auto-configuration packages].
169
169
For more control, use the `@Enable…Repositories` annotations from Spring Data.
170
170
171
171
For more about Spring Data, see the {url-spring-data-site}[Spring Data project page].
@@ -279,8 +279,8 @@ Then, add a `HibernatePropertiesCustomizer` bean as shown in the following examp
This customizer will configure Hibernate to use the same `CacheManager` as the one that the application uses.
283
-
It is also possible to use separate `CacheManager` instances.
282
+
This customizer will configure Hibernate to use the same `org.springframework.cache.CacheManager` as the one that the application uses.
283
+
It is also possible to use separate `org.springframework.cache.CacheManager` instances.
284
284
For details, see {url-hibernate-userguide}#caching-provider-jcache[the Hibernate user guide].
285
285
286
286
@@ -301,7 +301,7 @@ To take full control of the configuration of the `EntityManagerFactory`, you nee
301
301
Spring Boot auto-configuration switches off its entity manager in the presence of a bean of that type.
302
302
303
303
NOTE: When you create a bean for `LocalContainerEntityManagerFactoryBean` yourself, any customization that was applied during the creation of the auto-configured `LocalContainerEntityManagerFactoryBean` is lost.
304
-
Make sure to use the auto-configured `EntityManagerFactoryBuilder` to retain JPA and vendor properties.
304
+
Make sure to use the auto-configured `org.springframework.boot.orm.jpa.EntityManagerFactoryBuilder` to retain JPA and vendor properties.
305
305
This is particularly important if you were relying on `spring.jpa.*` properties for configuring things like the naming strategy or the DDL mode.
306
306
307
307
@@ -348,9 +348,9 @@ See {code-spring-boot-autoconfigure-src}/orm/jpa/JpaBaseConfiguration.java[`JpaB
Spring Data JPA and Spring Data Mongo can both automatically create `Repository` implementations for you.
351
+
Spring Data JPA and Spring Data Mongo can both automatically create `org.springframework.data.repository.Repository` implementations for you.
352
352
If they are both present on the classpath, you might have to do some extra configuration to tell Spring Boot which repositories to create.
353
-
The most explicit way to do that is to use the standard Spring Data `@EnableJpaRepositories` and `@EnableMongoRepositories` annotations and provide the location of your `Repository` interfaces.
353
+
The most explicit way to do that is to use the standard Spring Data `@EnableJpaRepositories` and `@EnableMongoRepositories` annotations and provide the location of your `org.springframework.data.repository.Repository` interfaces.
354
354
355
355
There are also flags (`+spring.data.*.repositories.enabled+` and `+spring.data.*.repositories.type+`) that you can use to switch the auto-configured repositories on and off in external configuration.
356
356
Doing so is useful, for instance, in case you want to switch off the Mongo repositories and still use the auto-configured `MongoTemplate`.
@@ -372,7 +372,7 @@ Note that if you are using Spring Data REST, you must use the properties in the
== Expose Spring Data Repositories as REST Endpoint
374
374
375
-
Spring Data REST can expose the `Repository` implementations as REST endpoints for you,
375
+
Spring Data REST can expose the `org.springframework.data.repository.Repository` implementations as REST endpoints for you,
376
376
provided Spring MVC has been enabled for the application.
377
377
378
378
Spring Boot exposes a set of useful properties (from the `spring.data.rest` namespace) that customize the javadoc:{url-spring-data-rest-javadoc}/org.springframework.data.rest.core.config.RepositoryRestConfiguration[].
Spring Boot can automatically create the schema (DDL scripts) of your JDBC `DataSource` or R2DBC `ConnectionFactory` and initialize its data (DML scripts).
36
+
Spring Boot can automatically create the schema (DDL scripts) of your JDBC `DataSource` or R2DBC `io.r2dbc.spi.ConnectionFactory` and initialize its data (DML scripts).
37
37
38
38
By default, it loads schema scripts from `optional:classpath*:schema.sql` and data scripts from `optional:classpath*:data.sql`.
39
39
The locations of these schema and data scripts can be customized using configprop:spring.sql.init.schema-locations[] and configprop:spring.sql.init.data-locations[] respectively.
@@ -139,9 +139,9 @@ If you would like more control, provide a `@Bean` that implements javadoc:org.sp
139
139
140
140
Flyway supports SQL and Java https://documentation.red-gate.com/fd/callback-concept-184127466.html[callbacks].
141
141
To use SQL-based callbacks, place the callback scripts in the `classpath:db/migration` directory.
142
-
To use Java-based callbacks, create one or more beans that implement `Callback`.
142
+
To use Java-based callbacks, create one or more beans that implement `org.flywaydb.core.api.callback.Callback`.
143
143
Any such beans are automatically registered with `Flyway`.
144
-
They can be ordered by using `@Order` or by implementing `Ordered`.
144
+
They can be ordered by using `@org.springframework.core.annotation.Order` or by implementing `org.springframework.core.Ordered`.
145
145
146
146
By default, Flyway autowires the (`@Primary`) `DataSource` in your context and uses that for migrations.
147
147
If you like to use a different `DataSource`, you can create one and mark its `@Bean` as `@FlywayDataSource`.
@@ -190,7 +190,7 @@ If any of the three properties has not been set, the value of its equivalent `sp
190
190
191
191
See javadoc:org.springframework.boot.autoconfigure.liquibase.LiquibaseProperties[] for details about available settings such as contexts, the default schema, and others.
192
192
193
-
You can also use a `Customizer<Liquibase>` bean if you want to customize the `Liquibase` instance before it is being used.
193
+
You can also use a `Customizer<Liquibase>` bean if you want to customize the `liquibase.Liquibase` instance before it is being used.
Copy file name to clipboardExpand all lines: spring-boot-project/spring-boot-docs/src/docs/antora/modules/how-to/pages/deployment/traditional-deployment.adoc
+1-1
Original file line number
Diff line number
Diff line change
@@ -91,7 +91,7 @@ If you have other features in your application (for instance, using other servle
91
91
92
92
* A `@Bean` of type `Servlet` or `ServletRegistrationBean` installs that bean in the container as if it were a `<servlet/>` and `<servlet-mapping/>` in `web.xml`.
93
93
* A `@Bean` of type `Filter` or `FilterRegistrationBean` behaves similarly (as a `<filter/>` and `<filter-mapping/>`).
94
-
* An `ApplicationContext` in an XML file can be added through an `@ImportResource` in your `Application`.
94
+
* An `ApplicationContext` in an XML file can be added through an `@ImportResource` in your `+Application+`.
95
95
Alternatively, cases where annotation configuration is heavily used already can be recreated in a few lines as `@Bean` definitions.
96
96
97
97
Once the war file is working, you can make it executable by adding a `main` method to your `+Application+`, as shown in the following example:
Copy file name to clipboardExpand all lines: spring-boot-project/spring-boot-docs/src/docs/antora/modules/how-to/pages/jersey.adoc
+2-2
Original file line number
Diff line number
Diff line change
@@ -10,7 +10,7 @@ Spring Security can be used to secure a Jersey-based web application in much the
10
10
However, if you want to use Spring Security's method-level security with Jersey, you must configure Jersey to use `setStatus(int)` rather `sendError(int)`.
11
11
This prevents Jersey from committing the response before Spring Security has had an opportunity to report an authentication or authorization failure to the client.
12
12
13
-
The `jersey.config.server.response.setStatusOverSendError` property must be set to `true` on the application's `ResourceConfig` bean, as shown in the following example:
13
+
The `jersey.config.server.response.setStatusOverSendError` property must be set to `true` on the application's `org.glassfish.jersey.server.ResourceConfig` bean, as shown in the following example:
To use Jersey alongside another web framework, such as Spring MVC, it should be configured so that it will allow the other framework to handle requests that it cannot handle.
23
23
First, configure Jersey to use a filter rather than a servlet by configuring the configprop:spring.jersey.type[] application property with a value of `filter`.
24
-
Second, configure your `ResourceConfig` to forward requests that would have resulted in a 404, as shown in the following example.
24
+
Second, configure your `org.glassfish.jersey.server.ResourceConfig` to forward requests that would have resulted in a 404, as shown in the following example.
Copy file name to clipboardExpand all lines: spring-boot-project/spring-boot-docs/src/docs/antora/modules/how-to/pages/logging.adoc
+4-4
Original file line number
Diff line number
Diff line change
@@ -50,10 +50,10 @@ These includes are designed to allow certain common Spring Boot conventions to b
50
50
The following files are provided under `org/springframework/boot/logging/logback/`:
51
51
52
52
* `defaults.xml` - Provides conversion rules, pattern properties and common logger configurations.
53
-
* `console-appender.xml` - Adds a `ConsoleAppender` using the `CONSOLE_LOG_PATTERN`.
54
-
* `structured-console-appender.xml` - Adds a `ConsoleAppender` using structured logging in the `CONSOLE_LOG_STRUCTURED_FORMAT`.
55
-
* `file-appender.xml` - Adds a `RollingFileAppender` using the `FILE_LOG_PATTERN` and `ROLLING_FILE_NAME_PATTERN` with appropriate settings.
56
-
* `structured-file-appender.xml` - Adds a `RollingFileAppender` using the `ROLLING_FILE_NAME_PATTERN` with structured logging in the `FILE_LOG_STRUCTURED_FORMAT`.
53
+
* `console-appender.xml` - Adds a `ch.qos.logback.core.ConsoleAppender` using the `CONSOLE_LOG_PATTERN`.
54
+
* `structured-console-appender.xml` - Adds a `ch.qos.logback.core.ConsoleAppender` using structured logging in the `CONSOLE_LOG_STRUCTURED_FORMAT`.
55
+
* `file-appender.xml` - Adds a `ch.qos.logback.core.rolling.RollingFileAppender` using the `FILE_LOG_PATTERN` and `ROLLING_FILE_NAME_PATTERN` with appropriate settings.
56
+
* `structured-file-appender.xml` - Adds a `ch.qos.logback.core.rolling.RollingFileAppender` using the `ROLLING_FILE_NAME_PATTERN` with structured logging in the `FILE_LOG_STRUCTURED_FORMAT`.
57
57
58
58
In addition, a legacy `base.xml` file is provided for compatibility with earlier versions of Spring Boot.
== Change the UserDetailsService and Add User Accounts
19
19
20
-
If you provide a `@Bean` of type `AuthenticationManager`, `AuthenticationProvider`, or `UserDetailsService`, the default `@Bean` for `InMemoryUserDetailsManager` is not created.
20
+
If you provide a `@Bean` of type `AuthenticationManager`, `org.springframework.security.authentication.AuthenticationProvider`, or `UserDetailsService`, the default `@Bean` for `InMemoryUserDetailsManager` is not created.
21
21
This means you have the full feature set of Spring Security available (such as {url-spring-security-docs}/servlet/authentication/index.html[various authentication options]).
22
22
23
23
The easiest way to add user accounts is by providing your own `UserDetailsService` bean.
0 commit comments