From 9ca70dc1d36622e94140f842bde5bd7e97b7a71a Mon Sep 17 00:00:00 2001 From: Spring Operator Date: Tue, 5 Mar 2019 21:57:32 -0600 Subject: [PATCH 1/3] URL Cleanup This commit updates URLs to prefer the https protocol. Redirects are not followed to avoid accidentally expanding intentionally shortened URLs (i.e. if using a URL shortener). # Fixed URLs ## Fixed But Review Recommended These URLs were fixed, but the https status was not OK. However, the https status was the same as the http request or http redirected to an https URL, so they were migrated. Your review is recommended. * http://quartz-scheduler.org/api/2.2.1/ (301) migrated to: https://www.quartz-scheduler.org/api/2.2.1/ ([https](https://quartz-scheduler.org/api/2.2.1/) result 404). ## Fixed Success These URLs were fixed successfully. * http://docs.jboss.org/jbossas/javadoc/4.0.5/connector/ migrated to: https://docs.jboss.org/jbossas/javadoc/4.0.5/connector/ ([https](https://docs.jboss.org/jbossas/javadoc/4.0.5/connector/) result 200). * http://docs.jboss.org/jbossas/javadoc/7.1.2.Final/ migrated to: https://docs.jboss.org/jbossas/javadoc/7.1.2.Final/ ([https](https://docs.jboss.org/jbossas/javadoc/7.1.2.Final/) result 200). * http://docs.oracle.com/cd/E13222_01/wls/docs90/javadocs/ migrated to: https://docs.oracle.com/cd/E13222_01/wls/docs90/javadocs/ ([https](https://docs.oracle.com/cd/E13222_01/wls/docs90/javadocs/) result 200). * http://docs.oracle.com/javaee/7/api/ migrated to: https://docs.oracle.com/javaee/7/api/ ([https](https://docs.oracle.com/javaee/7/api/) result 200). * http://docs.oracle.com/javase/8/docs/api/ migrated to: https://docs.oracle.com/javase/8/docs/api/ ([https](https://docs.oracle.com/javase/8/docs/api/) result 200). * http://fasterxml.github.io/jackson-core/javadoc/2.9/ migrated to: https://fasterxml.github.io/jackson-core/javadoc/2.9/ ([https](https://fasterxml.github.io/jackson-core/javadoc/2.9/) result 200). * http://fasterxml.github.io/jackson-databind/javadoc/2.9/ migrated to: https://fasterxml.github.io/jackson-databind/javadoc/2.9/ ([https](https://fasterxml.github.io/jackson-databind/javadoc/2.9/) result 200). * http://fasterxml.github.io/jackson-dataformat-xml/javadoc/2.9/ migrated to: https://fasterxml.github.io/jackson-dataformat-xml/javadoc/2.9/ ([https](https://fasterxml.github.io/jackson-dataformat-xml/javadoc/2.9/) result 200). * http://hc.apache.org/httpcomponents-client-ga/httpclient/apidocs/ migrated to: https://hc.apache.org/httpcomponents-client-ga/httpclient/apidocs/ ([https](https://hc.apache.org/httpcomponents-client-ga/httpclient/apidocs/) result 200). * http://issues.gradle.org/browse/GRADLE-1116 migrated to: https://issues.gradle.org/browse/GRADLE-1116 ([https](https://issues.gradle.org/browse/GRADLE-1116) result 200). * http://projectreactor.io/docs/core/release/api/ migrated to: https://projectreactor.io/docs/core/release/api/ ([https](https://projectreactor.io/docs/core/release/api/) result 200). * http://tiles.apache.org/framework/apidocs/ migrated to: https://tiles.apache.org/framework/apidocs/ ([https](https://tiles.apache.org/framework/apidocs/) result 200). * http://tiles.apache.org/tiles-request/apidocs/ migrated to: https://tiles.apache.org/tiles-request/apidocs/ ([https](https://tiles.apache.org/tiles-request/apidocs/) result 200). * http://www.apache.org/licenses/LICENSE-2.0 migrated to: https://www.apache.org/licenses/LICENSE-2.0 ([https](https://www.apache.org/licenses/LICENSE-2.0) result 200). * http://www.eclipse.org/aspectj/doc/released/aspectj5rt-api/ migrated to: https://www.eclipse.org/aspectj/doc/released/aspectj5rt-api/ ([https](https://www.eclipse.org/aspectj/doc/released/aspectj5rt-api/) result 200). * http://www.reactive-streams.org/reactive-streams-1.0.1-javadoc/ migrated to: https://www.reactive-streams.org/reactive-streams-1.0.1-javadoc/ ([https](https://www.reactive-streams.org/reactive-streams-1.0.1-javadoc/) result 200). * http://docs.spring.io/spring-framework/docs migrated to: https://docs.spring.io/spring-framework/docs ([https](https://docs.spring.io/spring-framework/docs) result 301). * http://glassfish.java.net/nonav/docs/v3/api/ migrated to: https://glassfish.java.net/nonav/docs/v3/api/ ([https](https://glassfish.java.net/nonav/docs/v3/api/) result 301). * http://pic.dhe.ibm.com/infocenter/wasinfo/v7r0/topic/com.ibm.websphere.javadoc.doc/web/apidocs/ migrated to: https://pic.dhe.ibm.com/infocenter/wasinfo/v7r0/topic/com.ibm.websphere.javadoc.doc/web/apidocs/ ([https](https://pic.dhe.ibm.com/infocenter/wasinfo/v7r0/topic/com.ibm.websphere.javadoc.doc/web/apidocs/) result 301). * http://projects.spring.io/spring-framework migrated to: https://projects.spring.io/spring-framework ([https](https://projects.spring.io/spring-framework) result 301). * http://springframework.org/schema migrated to: https://springframework.org/schema ([https](https://springframework.org/schema) result 301). * http://ehcache.org/apidocs/2.10.4 (301) migrated to: https://www.ehcache.org/apidocs/2.10.4 ([https](https://ehcache.org/apidocs/2.10.4) result 301). --- build.gradle | 32 ++++++++++++++++---------------- gradle/docs.gradle | 10 +++++----- gradle/ide.gradle | 2 +- gradle/publish-maven.gradle | 4 ++-- 4 files changed, 24 insertions(+), 24 deletions(-) diff --git a/build.gradle b/build.gradle index 96d0715f69c..e417afade83 100644 --- a/build.gradle +++ b/build.gradle @@ -175,22 +175,22 @@ configure(allprojects) { project -> } ext.javadocLinks = [ - "http://docs.oracle.com/javase/8/docs/api/", - "http://docs.oracle.com/javaee/7/api/", - "http://docs.oracle.com/cd/E13222_01/wls/docs90/javadocs/", // CommonJ - "http://pic.dhe.ibm.com/infocenter/wasinfo/v7r0/topic/com.ibm.websphere.javadoc.doc/web/apidocs/", - "http://glassfish.java.net/nonav/docs/v3/api/", - "http://docs.jboss.org/jbossas/javadoc/4.0.5/connector/", - "http://docs.jboss.org/jbossas/javadoc/7.1.2.Final/", - "http://tiles.apache.org/tiles-request/apidocs/", - "http://tiles.apache.org/framework/apidocs/", - "http://www.eclipse.org/aspectj/doc/released/aspectj5rt-api/", - "http://ehcache.org/apidocs/2.10.4", - "http://quartz-scheduler.org/api/2.2.1/", - "http://fasterxml.github.io/jackson-core/javadoc/2.9/", - "http://fasterxml.github.io/jackson-databind/javadoc/2.9/", - "http://fasterxml.github.io/jackson-dataformat-xml/javadoc/2.9/", - "http://hc.apache.org/httpcomponents-client-ga/httpclient/apidocs/", + "https://docs.oracle.com/javase/8/docs/api/", + "https://docs.oracle.com/javaee/7/api/", + "https://docs.oracle.com/cd/E13222_01/wls/docs90/javadocs/", // CommonJ + "https://pic.dhe.ibm.com/infocenter/wasinfo/v7r0/topic/com.ibm.websphere.javadoc.doc/web/apidocs/", + "https://glassfish.java.net/nonav/docs/v3/api/", + "https://docs.jboss.org/jbossas/javadoc/4.0.5/connector/", + "https://docs.jboss.org/jbossas/javadoc/7.1.2.Final/", + "https://tiles.apache.org/tiles-request/apidocs/", + "https://tiles.apache.org/framework/apidocs/", + "https://www.eclipse.org/aspectj/doc/released/aspectj5rt-api/", + "https://www.ehcache.org/apidocs/2.10.4", + "https://www.quartz-scheduler.org/api/2.2.1/", + "https://fasterxml.github.io/jackson-core/javadoc/2.9/", + "https://fasterxml.github.io/jackson-databind/javadoc/2.9/", + "https://fasterxml.github.io/jackson-dataformat-xml/javadoc/2.9/", + "https://hc.apache.org/httpcomponents-client-ga/httpclient/apidocs/", "https://junit.org/junit4/javadoc/4.12/", "https://junit.org/junit5/docs/${junit5Version}/api/" ] as String[] diff --git a/gradle/docs.gradle b/gradle/docs.gradle index 8102dfb5509..3e67b9093d4 100644 --- a/gradle/docs.gradle +++ b/gradle/docs.gradle @@ -5,7 +5,7 @@ * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * - * http://www.apache.org/licenses/LICENSE-2.0 + * https://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, @@ -72,10 +72,10 @@ dokka { packageListUrl = new File(buildDir, "api/package-list").toURI().toURL() } externalDocumentationLink { - url = new URL("http://projectreactor.io/docs/core/release/api/") + url = new URL("https://projectreactor.io/docs/core/release/api/") } externalDocumentationLink { - url = new URL("http://www.reactive-streams.org/reactive-streams-1.0.1-javadoc/") + url = new URL("https://www.reactive-streams.org/reactive-streams-1.0.1-javadoc/") } } @@ -114,7 +114,7 @@ task docsZip(type: Zip, dependsOn: ['api', 'asciidoctor', 'dokka']) { baseName = "spring-framework" classifier = "docs" description = "Builds -${classifier} archive containing api and reference " + - "for deployment at http://docs.spring.io/spring-framework/docs." + "for deployment at https://docs.spring.io/spring-framework/docs." from("src/dist") { include "changelog.txt" @@ -142,7 +142,7 @@ task schemaZip(type: Zip) { baseName = "spring-framework" classifier = "schema" description = "Builds -${classifier} archive containing all " + - "XSDs for deployment at http://springframework.org/schema." + "XSDs for deployment at https://springframework.org/schema." duplicatesStrategy 'exclude' moduleProjects.each { subproject -> def Properties schemas = new Properties(); diff --git a/gradle/ide.gradle b/gradle/ide.gradle index a643dbbb7f8..85fe8b4cf7f 100644 --- a/gradle/ide.gradle +++ b/gradle/ide.gradle @@ -11,7 +11,7 @@ eclipse.jdt { } // Replace classpath entries with project dependencies (GRADLE-1116) -// http://issues.gradle.org/browse/GRADLE-1116 +// https://issues.gradle.org/browse/GRADLE-1116 eclipse.classpath.file.whenMerged { classpath -> def regexp = /.*?\/([^\/]+)\/build\/([^\/]+\/)+(?:main|test)/ // only match those that end in main or test (avoids removing necessary entries like build/classes/jaxb) def projectOutputDependencies = classpath.entries.findAll { entry -> entry.path =~ regexp } diff --git a/gradle/publish-maven.gradle b/gradle/publish-maven.gradle index bbb6177e05f..dad95c8452f 100644 --- a/gradle/publish-maven.gradle +++ b/gradle/publish-maven.gradle @@ -30,12 +30,12 @@ def customizePom(pom, gradleProject) { url = "https://github.com/spring-projects/spring-framework" organization { name = "Spring IO" - url = "http://projects.spring.io/spring-framework" + url = "https://projects.spring.io/spring-framework" } licenses { license { name "Apache License, Version 2.0" - url "http://www.apache.org/licenses/LICENSE-2.0" + url "https://www.apache.org/licenses/LICENSE-2.0" distribution "repo" } } From 7eb1a421f730048a92833b7147d5c6e105d98754 Mon Sep 17 00:00:00 2001 From: Sam Brannen Date: Tue, 12 Mar 2019 17:52:46 +0100 Subject: [PATCH 2/3] Manual URL Cleanup Closes gh-22522 --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index e417afade83..029b26fe509 100644 --- a/build.gradle +++ b/build.gradle @@ -186,7 +186,7 @@ configure(allprojects) { project -> "https://tiles.apache.org/framework/apidocs/", "https://www.eclipse.org/aspectj/doc/released/aspectj5rt-api/", "https://www.ehcache.org/apidocs/2.10.4", - "https://www.quartz-scheduler.org/api/2.2.1/", + "https://www.quartz-scheduler.org/api/2.3.0/", "https://fasterxml.github.io/jackson-core/javadoc/2.9/", "https://fasterxml.github.io/jackson-databind/javadoc/2.9/", "https://fasterxml.github.io/jackson-dataformat-xml/javadoc/2.9/", From 8f7b118701bf28601c409f01b2da45e855c3eb81 Mon Sep 17 00:00:00 2001 From: Sam Brannen Date: Wed, 13 Mar 2019 15:12:51 +0100 Subject: [PATCH 3/3] Ensure PDF version of Reference Manual does not contain HTML tags Prior to this commit, the PDF version of the Spring Reference Manual contained HTML tags in code examples due to the fact that Asciidoctor converts bold formatting (i.e., elements wrapped in `**` or `*`) within source code blocks into HTML tags even for PDF rendering. This commit addresses this issue by removing all bold formatting from example code blocks. Closes gh-22577 --- src/docs/asciidoc/core/core-aop.adoc | 6 +-- src/docs/asciidoc/core/core-appendix.adoc | 2 +- src/docs/asciidoc/core/core-beans.adoc | 52 +++++++++---------- src/docs/asciidoc/core/core-validation.adoc | 2 +- src/docs/asciidoc/data-access.adoc | 12 ++--- src/docs/asciidoc/integration-appendix.adoc | 8 +-- src/docs/asciidoc/integration.adoc | 30 +++++------ .../asciidoc/languages/dynamic-languages.adoc | 4 +- src/docs/asciidoc/testing.adoc | 24 ++++----- src/docs/asciidoc/web/webflux-webclient.adoc | 2 +- src/docs/asciidoc/web/webflux.adoc | 6 +-- src/docs/asciidoc/web/webmvc.adoc | 10 ++-- src/docs/asciidoc/web/websocket.adoc | 6 +-- 13 files changed, 81 insertions(+), 83 deletions(-) diff --git a/src/docs/asciidoc/core/core-aop.adoc b/src/docs/asciidoc/core/core-aop.adoc index fbaf5c276a7..af738a18be9 100644 --- a/src/docs/asciidoc/core/core-aop.adoc +++ b/src/docs/asciidoc/core/core-aop.adoc @@ -1808,14 +1808,14 @@ respectively. For example, the previous pointcut can be better written as follow ==== [source,xml,indent=0] -[subs="verbatim,quotes"] +[subs="verbatim"] ---- + expression="execution(* com.xyz.myapp.service.*.*(..)) and this(service)"/> @@ -3331,7 +3331,7 @@ the following example: class="foo.StubEntitlementCalculationService"/> - **** + ---- ==== diff --git a/src/docs/asciidoc/core/core-appendix.adoc b/src/docs/asciidoc/core/core-appendix.adoc index 2909e4e9d0c..41b76d0e23c 100644 --- a/src/docs/asciidoc/core/core-appendix.adoc +++ b/src/docs/asciidoc/core/core-appendix.adoc @@ -875,7 +875,7 @@ use the `NamespaceHandlerSupport` class: public class MyNamespaceHandler extends NamespaceHandlerSupport { public void init() { - **registerBeanDefinitionParser("dateformat", new SimpleDateFormatBeanDefinitionParser());** + registerBeanDefinitionParser("dateformat", new SimpleDateFormatBeanDefinitionParser()); } } diff --git a/src/docs/asciidoc/core/core-beans.adoc b/src/docs/asciidoc/core/core-beans.adoc index 728b1c47d01..e52ab3898b5 100644 --- a/src/docs/asciidoc/core/core-beans.adoc +++ b/src/docs/asciidoc/core/core-beans.adoc @@ -2806,7 +2806,7 @@ to do so: [source,java,indent=0] [subs="verbatim,quotes"] ---- - **@RequestScope** + @RequestScope @Component public class LoginAction { // ... @@ -2846,7 +2846,7 @@ When using annotation-driven components or Java configuration, you can use the [source,java,indent=0] [subs="verbatim,quotes"] ---- - **@SessionScope** + @SessionScope @Component public class UserPreferences { // ... @@ -2885,7 +2885,7 @@ following example shows how to do so: [source,java,indent=0] [subs="verbatim,quotes"] ---- - **@ApplicationScope** + @ApplicationScope @Component public class AppPreferences { // ... @@ -4893,7 +4893,7 @@ primary `MovieCatalog`: public class MovieConfiguration { @Bean - **@Primary** + @Primary public MovieCatalog firstMovieCatalog() { ... } @Bean @@ -4938,7 +4938,7 @@ The corresponding bean definitions follow: - + @@ -4971,7 +4971,7 @@ shown in the following example: public class MovieRecommender { @Autowired - **@Qualifier("main")** + @Qualifier("main") private MovieCatalog movieCatalog; // ... @@ -4993,7 +4993,7 @@ method parameters, as shown in the following example: private CustomerPreferenceDao customerPreferenceDao; @Autowired - public void prepare(**@Qualifier("main")**MovieCatalog movieCatalog, + public void prepare(@Qualifier("main") MovieCatalog movieCatalog, CustomerPreferenceDao customerPreferenceDao) { this.movieCatalog = movieCatalog; this.customerPreferenceDao = customerPreferenceDao; @@ -5113,7 +5113,7 @@ provide the `@Qualifier` annotation within your definition, as the following exa ---- @Target({ElementType.FIELD, ElementType.PARAMETER}) @Retention(RetentionPolicy.RUNTIME) - **@Qualifier** + @Qualifier public @interface Genre { String value(); @@ -5131,13 +5131,13 @@ following example shows: public class MovieRecommender { @Autowired - **@Genre("Action")** + @Genre("Action") private MovieCatalog actionCatalog; private MovieCatalog comedyCatalog; @Autowired - public void setComedyCatalog(**@Genre("Comedy")** MovieCatalog comedyCatalog) { + public void setComedyCatalog(@Genre("Comedy") MovieCatalog comedyCatalog) { this.comedyCatalog = comedyCatalog; } @@ -5169,12 +5169,12 @@ demonstrates both approaches: - **** + - **** + @@ -5496,7 +5496,7 @@ named `movieFinder` injected into its setter method: private MovieFinder movieFinder; - **@Resource** + @Resource public void setMovieFinder(MovieFinder movieFinder) { this.movieFinder = movieFinder; } @@ -5705,7 +5705,7 @@ You can then use `@SessionScope` without declaring the `proxyMode` as follows: [subs="verbatim,quotes"] ---- @Service - **@SessionScope** + @SessionScope public class SessionScopedService { // ... } @@ -5719,7 +5719,7 @@ You can also override the value for the `proxyMode`, as the following example sh [subs="verbatim,quotes"] ---- @Service - **@SessionScope(proxyMode = ScopedProxyMode.INTERFACES)** + @SessionScope(proxyMode = ScopedProxyMode.INTERFACES) public class SessionScopedUserService implements UserService { // ... } @@ -6248,7 +6248,7 @@ technique: [subs="verbatim,quotes"] ---- @Component - **@Qualifier("Action")** + @Qualifier("Action") public class ActionMovieCatalog implements MovieCatalog { // ... } @@ -6258,7 +6258,7 @@ technique: [subs="verbatim,quotes"] ---- @Component - **@Genre("Action")** + @Genre("Action") public class ActionMovieCatalog implements MovieCatalog { // ... } @@ -6268,7 +6268,7 @@ technique: [subs="verbatim,quotes"] ---- @Component - **@Offline** + @Offline public class CachingMovieCatalog implements MovieCatalog { // ... } @@ -7189,7 +7189,7 @@ as the following example shows: public class MyConfiguration { @Bean - **@Scope("prototype")** + @Scope("prototype") public Encryptor encryptor() { // ... } @@ -7217,7 +7217,7 @@ it resembles the following: ---- // an HTTP Session-scoped bean exposed as a proxy @Bean - **@SessionScope** + @SessionScope public UserPreferences userPreferences() { return new UserPreferences(); } @@ -7298,7 +7298,7 @@ annotation, as the following example shows: public class AppConfig { @Bean - **@Description("Provides a basic example of a bean")** + @Description("Provides a basic example of a bean") public Thing thing() { return new Thing(); } @@ -8127,7 +8127,7 @@ can rewrite the `dataSource` configuration as follows: [subs="verbatim,quotes"] ---- @Configuration - **@Profile("development")** + @Profile("development") public class StandaloneDataConfig { @Bean @@ -8145,7 +8145,7 @@ can rewrite the `dataSource` configuration as follows: [subs="verbatim,quotes"] ---- @Configuration - **@Profile("production")** + @Profile("production") public class JndiDataConfig { @Bean(destroyMethod="") @@ -8186,7 +8186,7 @@ of creating a custom composed annotation. The following example defines a custom ---- @Target(ElementType.TYPE) @Retention(RetentionPolicy.RUNTIME) - **@Profile("production")** + @Profile("production") public @interface Production { } ---- @@ -8423,7 +8423,7 @@ following example: [subs="verbatim,quotes"] ---- @Configuration - **@Profile("default")** + @Profile("default") public class DefaultDataConfig { @Bean @@ -8540,7 +8540,7 @@ a call to `testBean.getName()` returns `myTestBean`: [subs="verbatim,quotes"] ---- @Configuration - **@PropertySource("classpath:/com/myco/app.properties")** + @PropertySource("classpath:/com/myco/app.properties") public class AppConfig { @Autowired diff --git a/src/docs/asciidoc/core/core-validation.adoc b/src/docs/asciidoc/core/core-validation.adoc index 8b749accf2e..7795ea2fac0 100644 --- a/src/docs/asciidoc/core/core-validation.adoc +++ b/src/docs/asciidoc/core/core-validation.adoc @@ -707,7 +707,7 @@ implementation of an `initBinder(..)` method: protected void initBinder(HttpServletRequest request, ServletRequestDataBinder binder) throws Exception { - **this.customPropertyEditorRegistrar.registerCustomEditors(binder);** + this.customPropertyEditorRegistrar.registerCustomEditors(binder); } // other methods to do with registering a User diff --git a/src/docs/asciidoc/data-access.adoc b/src/docs/asciidoc/data-access.adoc index 9583e6ea1b4..25ce53fa595 100644 --- a/src/docs/asciidoc/data-access.adoc +++ b/src/docs/asciidoc/data-access.adoc @@ -1078,7 +1078,7 @@ Consider the following class definition: [subs="verbatim,quotes"] ---- // the service class that we want to make transactional - **@Transactional** + @Transactional public class DefaultFooService implements FooService { Foo getFoo(String fooName); @@ -1553,7 +1553,7 @@ The following code shows the simple profiling aspect discussed earlier: this.order = order; } - // this method *is* the around advice + // this method is the around advice public Object profile(ProceedingJoinPoint call) throws Throwable { Object returnValue; StopWatch clock = new StopWatch(getClass().getName()); @@ -1817,7 +1817,7 @@ with an anonymous class, as follows: [source,java,indent=0] [subs="verbatim,quotes"] ---- - transactionTemplate.execute(new **TransactionCallbackWithoutResult**() { + transactionTemplate.execute(new TransactionCallbackWithoutResult() { protected void doInTransactionWithoutResult(TransactionStatus status) { updateOperation1(); updateOperation2(); @@ -1840,7 +1840,7 @@ Code within the callback can roll the transaction back by calling the updateOperation1(); updateOperation2(); } catch (SomeBusinessException ex) { - **status.setRollbackOnly();** + status.setRollbackOnly(); } } }); @@ -2606,7 +2606,7 @@ the setter for the `DataSource`. This leads to DAOs that resemble the following: private JdbcTemplate jdbcTemplate; public void setDataSource(DataSource dataSource) { - **this.jdbcTemplate = new JdbcTemplate(dataSource);** + this.jdbcTemplate = new JdbcTemplate(dataSource); } // JDBC-backed implementations of the methods on the CorporateEventDao follow... @@ -5044,7 +5044,7 @@ errors in the SQL it executes from the scripts, as the following example shows: [source,xml,indent=0] [subs="verbatim,quotes"] ---- - + ---- diff --git a/src/docs/asciidoc/integration-appendix.adoc b/src/docs/asciidoc/integration-appendix.adoc index 9f2883dc3be..067df57d7af 100644 --- a/src/docs/asciidoc/integration-appendix.adoc +++ b/src/docs/asciidoc/integration-appendix.adoc @@ -47,12 +47,12 @@ The following example shows how to use JNDI to look up a data source without the [source,xml,indent=0] [subs="verbatim,quotes"] ---- - + - + ---- ==== @@ -64,11 +64,11 @@ schema: [source,xml,indent=0] [subs="verbatim,quotes"] ---- - + - + ---- ==== diff --git a/src/docs/asciidoc/integration.adoc b/src/docs/asciidoc/integration.adoc index be27bbf953f..b3946ece979 100644 --- a/src/docs/asciidoc/integration.adoc +++ b/src/docs/asciidoc/integration.adoc @@ -2119,7 +2119,7 @@ containers that ships with Spring (in this case, `DefaultMessageListenerContaine - **** + ---- ==== @@ -2219,17 +2219,17 @@ POJO that we can make into an MDP through the following configuration: [subs="verbatim,quotes"] ---- - ** + - ** + - **** + ---- ==== @@ -2346,7 +2346,7 @@ Consider the following bean definition: - **** + ---- ==== @@ -2818,7 +2818,7 @@ namespace elements, you need to reference the JMS schema, as the following examp xmlns:jms="http://www.springframework.org/schema/jms" <1> xsi:schemaLocation=" http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd - **http://www.springframework.org/schema/jms http://www.springframework.org/schema/jms/spring-jms.xsd**"> + http://www.springframework.org/schema/jms http://www.springframework.org/schema/jms/spring-jms.xsd"> @@ -7323,13 +7323,13 @@ do yourself a favor and read < findBook(String name) ---- ==== @@ -7977,11 +7977,11 @@ Spring's abstraction and the other using JCache: [source,java,indent=0] [subs="verbatim,quotes"] ---- - @Cacheable(cacheNames="books", **key="#isbn"**) + @Cacheable(cacheNames="books", key="#isbn") public Book findBook(ISBN isbn, boolean checkWarehouse, boolean includeUsed) @CacheResult(cacheName="books") - public Book findBook(**@CacheKey** ISBN isbn, boolean checkWarehouse, boolean includeUsed) + public Book findBook(@CacheKey ISBN isbn, boolean checkWarehouse, boolean includeUsed) ---- ==== @@ -8000,8 +8000,8 @@ invoking the method again: [source,java,indent=0] [subs="verbatim,quotes"] ---- - @CacheResult(cacheName="books", **exceptionCacheName="failures"** - **cachedExceptions = InvalidIsbnNotFoundException.class**) + @CacheResult(cacheName="books", exceptionCacheName="failures" + cachedExceptions = InvalidIsbnNotFoundException.class) public Book findBook(ISBN isbn) ---- ==== diff --git a/src/docs/asciidoc/languages/dynamic-languages.adoc b/src/docs/asciidoc/languages/dynamic-languages.adoc index ebad1c630f5..db3092a7cbd 100644 --- a/src/docs/asciidoc/languages/dynamic-languages.adoc +++ b/src/docs/asciidoc/languages/dynamic-languages.adoc @@ -417,9 +417,9 @@ does not work: ---- - + - + diff --git a/src/docs/asciidoc/testing.adoc b/src/docs/asciidoc/testing.adoc index 8afc4f7e23a..379bcc789ba 100644 --- a/src/docs/asciidoc/testing.adoc +++ b/src/docs/asciidoc/testing.adoc @@ -3346,11 +3346,11 @@ The first code listing shows a JUnit 4 based implementation of the test class th ---- @RunWith(SpringRunner.class) // specifies the Spring configuration to load for this test fixture - **@ContextConfiguration("repository-config.xml")** + @ContextConfiguration("repository-config.xml") public class HibernateTitleRepositoryTests { // this instance will be dependency injected by type - **@Autowired** + @Autowired private HibernateTitleRepository titleRepository; @Test @@ -3371,13 +3371,13 @@ follows: ---- @RunWith(SpringRunner.class) // specifies the Spring configuration to load for this test fixture - **@ContextConfiguration("repository-config.xml")** + @ContextConfiguration("repository-config.xml") public class HibernateTitleRepositoryTests { // this instance will be dependency injected by type private HibernateTitleRepository titleRepository; - **@Autowired** + @Autowired public void setTitleRepository(HibernateTitleRepository titleRepository) { this.titleRepository = titleRepository; } @@ -3406,7 +3406,7 @@ shows this configuration: http://www.springframework.org/schema/beans/spring-beans.xsd"> - + @@ -3435,8 +3435,8 @@ method in the superclass as well): @Autowired @Override - public void setDataSource(**@Qualifier("myDataSource")** DataSource dataSource) { - **super**.setDataSource(dataSource); + public void setDataSource(@Qualifier("myDataSource") DataSource dataSource) { + super.setDataSource(dataSource); } // ... @@ -3809,11 +3809,11 @@ following example shows the relevant annotations in bold: ---- @RunWith(SpringRunner.class) @ContextConfiguration - **@Transactional(transactionManager = "txMgr")** - **@Commit** + @Transactional(transactionManager = "txMgr") + @Commit public class FictitiousTransactionalTest { - **@BeforeTransaction** + @BeforeTransaction void verifyInitialDatabaseState() { // logic to verify the initial state before a transaction is started } @@ -3825,7 +3825,7 @@ following example shows the relevant annotations in bold: @Test // overrides the class-level @Commit setting - **@Rollback** + @Rollback public void modifyDatabaseWithinTransaction() { // logic which uses the test data and modifies database state } @@ -3835,7 +3835,7 @@ following example shows the relevant annotations in bold: // execute "tear down" logic within the transaction } - **@AfterTransaction** + @AfterTransaction void verifyFinalDatabaseState() { // logic to verify the final state after transaction has rolled back } diff --git a/src/docs/asciidoc/web/webflux-webclient.adoc b/src/docs/asciidoc/web/webflux-webclient.adoc index 6964090f820..78c7045f507 100644 --- a/src/docs/asciidoc/web/webflux-webclient.adoc +++ b/src/docs/asciidoc/web/webflux-webclient.adoc @@ -475,7 +475,7 @@ through the `syncBody` method, as the following example shows: Mono result = client.post() .uri("/path", id) - .syncBody(**builder.build()**) + .syncBody(builder.build()) .retrieve() .bodyToMono(Void.class); ---- diff --git a/src/docs/asciidoc/web/webflux.adoc b/src/docs/asciidoc/web/webflux.adoc index 57a5bbc94c5..72d977482a9 100644 --- a/src/docs/asciidoc/web/webflux.adoc +++ b/src/docs/asciidoc/web/webflux.adoc @@ -1339,7 +1339,7 @@ as the following example shows: [source,java,indent=0] [subs="verbatim,quotes"] ---- - @PostMapping(path = "/pets", **consumes = "application/json"**) + @PostMapping(path = "/pets", consumes = "application/json") public void addPet(@RequestBody Pet pet) { // ... } @@ -1368,7 +1368,7 @@ content types that a controller method produces, as the following example shows: [source,java,indent=0] [subs="verbatim,quotes"] ---- - @GetMapping(path = "/pets/{petId}", **produces = "application/json;charset=UTF-8"**) + @GetMapping(path = "/pets/{petId}", produces = "application/json;charset=UTF-8") @ResponseBody public Pet getPet(@PathVariable String petId) { // ... @@ -2023,7 +2023,7 @@ You can automatically apply validation after data binding by adding the [subs="verbatim,quotes"] ---- @PostMapping("/owners/{ownerId}/pets/{petId}/edit") - public String processSubmit(**@Valid @ModelAttribute("pet") Pet pet**, BindingResult result) { <1> + public String processSubmit(@Valid @ModelAttribute("pet") Pet pet, BindingResult result) { <1> if (result.hasErrors()) { return "petForm"; } diff --git a/src/docs/asciidoc/web/webmvc.adoc b/src/docs/asciidoc/web/webmvc.adoc index bb67800b463..6d097493f45 100644 --- a/src/docs/asciidoc/web/webmvc.adoc +++ b/src/docs/asciidoc/web/webmvc.adoc @@ -2078,7 +2078,7 @@ The following example shows how to do so: // ... @GetMapping - public String setupForm(**@RequestParam("petId") int petId**, Model model) { <1> + public String setupForm(@RequestParam("petId") int petId, Model model) { <1> Pet pet = this.clinic.loadPet(petId); model.addAttribute("pet", pet); return "petForm"; @@ -2633,8 +2633,8 @@ probably want it deserialized from JSON (similar to `@RequestBody`). Use the [subs="verbatim,quotes"] ---- @PostMapping("/") -public String handle(**@RequestPart("meta-data") MetaData metadata, - @RequestPart("file-data") MultipartFile file**) { +public String handle(@RequestPart("meta-data") MetaData metadata, + @RequestPart("file-data") MultipartFile file) { // ... } ---- @@ -2652,8 +2652,8 @@ as the following example shows: [subs="verbatim,quotes"] ---- @PostMapping("/") -public String handle(**@Valid** @RequestPart("meta-data") MetaData metadata, - **BindingResult result**) { +public String handle(@Valid @RequestPart("meta-data") MetaData metadata, + BindingResult result) { // ... } ---- diff --git a/src/docs/asciidoc/web/websocket.adoc b/src/docs/asciidoc/web/websocket.adoc index b5683c7f624..7538b9ac929 100644 --- a/src/docs/asciidoc/web/websocket.adoc +++ b/src/docs/asciidoc/web/websocket.adoc @@ -1743,7 +1743,7 @@ The following example shows how to do so in Java configuration: @Override public void configureMessageBroker(MessageBrokerRegistry registry) { - registry.setPathMatcher(**new AntPathMatcher("."));** + registry.setPathMatcher(new AntPathMatcher(".")); registry.enableStompBrokerRelay("/queue", "/topic"); registry.setApplicationDestinationPrefixes("/app"); } @@ -1766,16 +1766,14 @@ The following example shows the XML configuration equivalent of the preceding ex http://www.springframework.org/schema/websocket http://www.springframework.org/schema/websocket/spring-websocket.xsd"> - + - ** - ** ----