-
Notifications
You must be signed in to change notification settings - Fork 41.6k
Editing pass for howto.adoc #10854
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
Editing pass for howto.adoc #10854
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks once again, Jay. I've left a few comments as well as trying to answer your TODOs.
| validations and more. It is actually very easy to create your own. | ||
| in a {dc-spring-boot}/diagnostics/FailureAnalysis.{dc-ext}[`FailureAnalysis`]. Spring | ||
| Boot provides such an analyzer for application-context-related exceptions, JSR-303 | ||
| validations, and more. It is actually very easy to create your own. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"It is actually very easy to create your own" -> "You can also create your own"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch. Thank you. :)
| running 2 applications from the same code base) then you can explicitly call | ||
| `setWebEnvironment(false)` on your `SpringApplication` instance, or set the | ||
| execute some code in a `main` method but also bootstrap a Spring application to set up | ||
| the infrastructure to use, you can the `SpringApplication` features of Spring |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"you can the" -> "you can use the"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yup. Thanks.
| `applicationContextClass` property (through the Java API or with external properties). | ||
| Application code that you want to run as your business logic can be implemented as a | ||
| `CommandLineRunner` and dropped into the context as a `@Bean` definition. | ||
|
|
||
|
|
||
|
|
||
| [[howto-properties-and-configuration]] | ||
| == Properties & configuration | ||
| == Properties & Configuration |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not your doing, but should we use "and" rather than "&" here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, we should. I'm so accustomed to ampersands from all my XML work that I read right past them. Good catch. Thanks.
|
|
||
|
|
||
|
|
||
| [[howto-add-a-servlet-filter-or-listener]] | ||
| === Add a Servlet, Filter or Listener to an application | ||
| There are two ways to add `Servlet`, `Filter`, `ServletContextListener` and the other | ||
| === Add a Servlet, Filter or Listener to an Application |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"Filter or Listener" -> "Filter, or Listener" to be consistent with the change below?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yup (and to be consistent with adding serial commas everywhere). Thanks.
| @@ -1162,12 +1177,12 @@ source code for more details. | |||
| [[howto-multipart-file-upload-configuration]] | |||
| === Handling Multipart File Uploads | |||
| Spring Boot embraces the Servlet 3 `javax.servlet.http.Part` API to support uploading | |||
| files. By default Spring Boot configures Spring MVC with a maximum file of 1MB per | |||
| files. By default, Spring Boot configures Spring MVC with a maximum file of 1MB per | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not your doing, but "maximum file" -> "maximum size"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes. Good catch. Thanks.
| for details. | ||
|
|
||
| If Groovy is on the classpath you should be able to configure Logback with | ||
| `logback.groovy` as well (it will be given preference if present). | ||
| If Groovy is on the classpath you, should be able to configure Logback with |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"classpath you," -> "classpath, you"?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yup. Thanks.
| output using Log4j 2). See the Actuator Log4j 2 samples for more detail and to see it in | ||
| action. | ||
|
|
||
| // TODO Link? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
{github-code}/spring-boot-samples/spring-boot-sample-actuator-log4j2
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you. :)
| for details of available settings) and `SECURITY` section of | ||
| <<common-application-properties-security,Common application properties>>. | ||
| for details of available settings) and the `SECURITY` section of | ||
| "`<<common-application-properties-security,Common Ppplication Properties>>`". |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"Ppplication" -> "Application"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll just go crawl under this rock over here....
Thanks.
| anyway, since it was relying on the order of plugin executions. In Maven, the executable | ||
| jar must be the main artifact and you can add a classified jar for the library, as follows: | ||
| // TODO Some of the original content had past tense. Has the `forceCreation` attribute | ||
| // been deprecated? If not, I'll re-arrange the sentences to indicate that it still works. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure why it's written in the past tense. The property still exists and has not been deprecated as far as I can tell: https://maven.apache.org/plugins/maven-jar-plugin/jar-mojo.html#forceCreation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I removed the first part of that paragraph, since it seemed to be disconnected from other content (we mentioned the force-creation attribute and then didn't use it in the example or anywhere else. If we need to restore, we need to think of something useful to say about it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Thanks.
| @@ -3058,7 +3114,7 @@ Example in Maven: | |||
| </dependency> | |||
| ---- | |||
|
|
|||
| Example in Gradle: | |||
| The following example shows how to do soin Gradle: | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"soin" -> "so in"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yessir. Thanks.
I made it more formal and corrected sentence errors. I also added some links and asked a couple questions in TODOs.
Andy caught some of my goofs and some other folks' goofs. He also answered the questions I had left as TODO items. I made the various changes. Thanks, Andy.
* gh-10854: Make editorial changes to howto.adoc
|
Thanks once again, @Buzzardo. These changes are now in master. |
I made it more formal and corrected sentence errors. I also added some links and asked a couple questions in TODOs.