Skip to content

Editing pass for the Actuator section #27759

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

Closed
wants to merge 2 commits into from
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.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,9 @@
= Production-ready Features
include::attributes.adoc[]



Spring Boot includes a number of additional features to help you monitor and manage your application when you push it to production.
You can choose to manage and monitor your application by using HTTP endpoints or with JMX.
Auditing, health, and metrics gathering can also be automatically applied to your application.


You can also automatically apply auditing, health, and metrics gathering to your application.

include::actuator/enabling.adoc[]

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
Once Spring Security is in play, Spring Boot Actuator has a flexible audit framework that publishes events (by default, "`authentication success`", "`failure`" and "`access denied`" exceptions).
This feature can be very useful for reporting and for implementing a lock-out policy based on authentication failures.

Auditing can be enabled by providing a bean of type `AuditEventRepository` in your application's configuration.
You can enable auditing by providing a bean of type `AuditEventRepository` in your application's configuration.
For convenience, Spring Boot offers an `InMemoryAuditEventRepository`.
`InMemoryAuditEventRepository` has limited capabilities and we recommend using it only for development environments.
`InMemoryAuditEventRepository` has limited capabilities, and we recommend using it only for development environments.
For production environments, consider creating your own alternative `AuditEventRepository` implementation.


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,17 @@ Spring Boot's actuator module includes additional support that is activated when
The `/cloudfoundryapplication` path provides an alternative secured route to all `@Endpoint` beans.

The extended support lets Cloud Foundry management UIs (such as the web application that you can use to view deployed applications) be augmented with Spring Boot actuator information.
For example, an application status page may include full health information instead of the typical "`running`" or "`stopped`" status.
For example, an application status page can include full health information instead of the typical "`running`" or "`stopped`" status.

NOTE: The `/cloudfoundryapplication` path is not directly accessible to regular users.
In order to use the endpoint, a valid UAA token must be passed with the request.
To use the endpoint, you must pass a valid UAA token with the request.



[[actuator.cloud-foundry.disable]]
=== Disabling Extended Cloud Foundry Actuator Support
If you want to fully disable the `/cloudfoundryapplication` endpoints, you can add the following setting to your `application.properties` file:


[source,yaml,indent=0,subs="verbatim",configprops,configblocks]
----
management:
Expand All @@ -41,12 +40,12 @@ If your Cloud Foundry UAA or Cloud Controller services use self-signed certifica

[[actuator.cloud-foundry.custom-context-path]]
=== Custom Context Path
If the server's context-path has been configured to anything other than `/`, the Cloud Foundry endpoints will not be available at the root of the application.
For example, if `server.servlet.context-path=/app`, Cloud Foundry endpoints will be available at `/app/cloudfoundryapplication/*`.
If the server's context-path has been configured to anything other than `/`, the Cloud Foundry endpoints are not available at the root of the application.
For example, if `server.servlet.context-path=/app`, Cloud Foundry endpoints are available at `/app/cloudfoundryapplication/*`.

If you expect the Cloud Foundry endpoints to always be available at `/cloudfoundryapplication/*`, regardless of the server's context-path, you will need to explicitly configure that in your application.
The configuration will differ depending on the web server in use.
For Tomcat, the following configuration can be added:
If you expect the Cloud Foundry endpoints to always be available at `/cloudfoundryapplication/*`, regardless of the server's context-path, you need to explicitly configure that in your application.
The configuration differs, depending on the web server in use.
For Tomcat, you can add the following configuration:

[source,java,indent=0,subs="verbatim"]
----
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
[[actuator.enabling]]
== Enabling Production-ready Features
The {spring-boot-code}/spring-boot-project/spring-boot-actuator[`spring-boot-actuator`] module provides all of Spring Boot's production-ready features.
The recommended way to enable the features is to add a dependency on the `spring-boot-starter-actuator` '`Starter`'.
The recommended way to enable the features is to add a dependency on the `spring-boot-starter-actuator` "`Starter`".

.Definition of Actuator
****
An actuator is a manufacturing term that refers to a mechanical device for moving or controlling something.
Actuators can generate a large amount of motion from a small change.
****

To add the actuator to a Maven based project, add the following '`Starter`' dependency:
To add the actuator to a Maven-based project, add the following '`Starter`' dependency:

[source,xml,indent=0,subs="verbatim"]
----
Expand Down
Loading