Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in / Register
Toggle navigation
S
spring-boot
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
DEMO
spring-boot
Commits
fd53945f
Commit
fd53945f
authored
Apr 10, 2017
by
Stephane Nicoll
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Polish "Document HTTP response format of health endpoint"
Closes gh-8703
parent
1fa1ed2b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
7 deletions
+9
-7
production-ready-features.adoc
...oot-docs/src/main/asciidoc/production-ready-features.adoc
+9
-7
No files found.
spring-boot-docs/src/main/asciidoc/production-ready-features.adoc
View file @
fd53945f
...
...
@@ -382,9 +382,15 @@ to your application properties:
management
.
health
.
status
.
order
=
DOWN
,
OUT_OF_SERVICE
,
UNKNOWN
,
UP
----
You
might
also
want
to
register
custom
status
mappings
with
the
`
HealthMvcEndpoint
`
if
you
access
the
health
endpoint
over
HTTP
.
For
example
you
could
map
`
FATAL
`
to
`
HttpStatus
.
SERVICE_UNAVAILABLE
`.
The
HTTP
status
code
in
the
response
reflects
the
overall
health
status
(
e
.
g
.
`
UP
`
maps
to
200
,
`
OUT_OF_SERVICE
`
or
`
DOWN
`
to
503
).
You
might
also
want
to
register
custom
status
mappings
with
the
`
HealthMvcEndpoint
`
if
you
access
the
health
endpoint
over
HTTP
.
For
example
,
the
following
maps
`
FATAL
`
to
`
HttpStatus
.
SERVICE_UNAVAILABLE
`:
[
source
,
properties
,
indent
=
0
]
----
endpoints
.
health
.
mappings
.
FATAL
=
503
----
...
...
@@ -688,10 +694,6 @@ endpoint being used in a denial of service attack. The `endpoints.health.time-to
property is used to configure the caching period in milliseconds. It defaults to 1000,
i.e. one second.
The HTTP status code in the response reflects the overall health status (e.g. “UP”=200,
“OUT_OF_SERVICE”=503, “DOWN”=503). The mappings can be changed by configuring
`endpoints.health.mapping.<STATUS>=XXX`.
Sample summarized HTTP response (default for anonymous request):
[source,indent=0]
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment