-
Notifications
You must be signed in to change notification settings - Fork 13
/
draft-inadarei-api-health-check-00.xml
704 lines (585 loc) · 31.7 KB
/
draft-inadarei-api-health-check-00.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" href="rfc2629.xslt" ?>
<!-- generated by https://github.com/cabo/kramdown-rfc2629 version 1.2.7 -->
<!DOCTYPE rfc SYSTEM "rfc2629.dtd" [
]>
<?rfc toc="yes"?>
<?rfc tocindent="yes"?>
<?rfc sortrefs="yes"?>
<?rfc symrefs="yes"?>
<?rfc strict="yes"?>
<?rfc compact="yes"?>
<?rfc comments="yes"?>
<?rfc inline="yes"?>
<rfc ipr="trust200902" docName="draft-inadarei-api-health-check-00" category="info">
<front>
<title>Health Check Response Format for HTTP APIs</title>
<author initials="I." surname="Nadareishvili" fullname="Irakli Nadareishvili">
<organization></organization>
<address>
<postal>
<street>114 5th Avenue</street>
<city>New York</city>
<country>United States</country>
</postal>
<email>irakli@gmail.com</email>
<uri>http://www.freshblurbs.com</uri>
</address>
</author>
<date year="2018"/>
<area>General</area>
<keyword>Internet-Draft</keyword>
<abstract>
<t>This document proposes a service health check response format for HTTP APIs.</t>
</abstract>
<note title="Note to Readers">
<t><spanx style="strong">RFC EDITOR: please remove this section before publication</spanx></t>
<t>The issues list for this draft can be found at <eref target="https://github.com/inadarei/rfc-healthcheck/issues">https://github.com/inadarei/rfc-healthcheck/issues</eref>.</t>
<t>The most recent draft is at <eref target="https://inadarei.github.io/rfc-healthcheck/">https://inadarei.github.io/rfc-healthcheck/</eref>.</t>
<t>Recent changes are listed at <eref target="https://github.com/inadarei/rfc-healthcheck/commits/master">https://github.com/inadarei/rfc-healthcheck/commits/master</eref>.</t>
<t>See also the draft’s current status in the IETF datatracker, at
<eref target="https://datatracker.ietf.org/doc/draft-inadarei-api-health-check/">https://datatracker.ietf.org/doc/draft-inadarei-api-health-check/</eref>.</t>
</note>
</front>
<middle>
<section anchor="introduction" title="Introduction">
<t>The vast majority of modern APIs driving data to web and mobile applications
use HTTP <xref target="RFC7230"/> as their protocol. The health and uptime of these
APIs determine availability of the applications themselves. In distributed
systems built with a number of APIs, understanding the health status of the APIs
and making corresponding decisions, for failover or circuit-breaking, are
essential for providing highly available solutions.</t>
<t>There exists a wide variety of operational software that relies on the ability
to read health check response of APIs. There is currently no standard for the
health check output response, however, so most applications either rely on the
basic level of information included in HTTP status codes <xref target="RFC7231"/> or use
task-specific formats.</t>
<t>Usage of task-specific or application-specific formats creates significant
challenges, disallowing any meaningful interoperability across different
implementations and between different tooling.</t>
<t>Standardizing a format for health checks can provide any of a number of
benefits, including:</t>
<t><list style="symbols">
<t>Flexible deployment - since operational tooling and API clients can rely on
rich, uniform format, they can be safely combined and substituted as needed.</t>
<t>Evolvability - new APIs, conforming to the standard, can safely be introduced
in any environment and ecosystem that also conforms to the same standard,
without costly coordination and testing requirements.</t>
</list></t>
<t>This document defines a “health check” format using the JSON format <xref target="RFC8259"/>
for APIs to use as a standard point for the health information they offer.
Having a well-defined format for this purpose promotes good practice and
tooling.</t>
</section>
<section anchor="notational-conventions" title="Notational Conventions">
<t>The key words “MUST”, “MUST NOT”, “REQUIRED”, “SHALL”, “SHALL NOT”, “SHOULD”,
“SHOULD NOT”, “RECOMMENDED”, “MAY”, and “OPTIONAL” in this document are to be
interpreted as described in <xref target="RFC2119"/>.</t>
</section>
<section anchor="api-health-response" title="API Health Response">
<t>The API Health Response Format (or, interchangeably, “health check response
format”) uses the JSON format described in <xref target="RFC8259"/> and has the media type
“application/health+json”.</t>
<t>Its content consists of a single mandatory root field (“status”) and several
optional fields:</t>
<t><list style="symbols">
<t>status: (required) indicates whether the service status is acceptable or not.
API publishers SHOULD use following values for the field: <list style="symbols">
<t>“pass”: healthy,</t>
<t>“fail”: unhealthy, and</t>
<t>“warn”: healthy, with some concerns.</t>
</list>
The value of the status field is tightly related with the HTTP response code
returned by the health endpoint. For “pass” and “warn” statuses HTTP response
code in the 2xx-3xx range MUST be used. For “fail” status HTTP response code
in the 4xx-5xx range MUST be used. In case of the “warn” status, endpoint
SHOULD return HTTP status in the 2xx-3xx range and additional information
SHOULD be provided, utilizing optional fields of the response. <vspace blankLines='1'/>
A health endpoint is only meaningful in the context of the component it
indicates the health of. It has no other meaning or purpose. As such, its
health is a conduit to the health of the component. Clients SHOULD assume that
the HTTP response code returned by the health endpoint is applicable to the
entire component (e.g. a larger API or a microservice). This is compatible
with the behavior that current infrastructural tooling expects:
load-balancers, service discoveries and others, utilizing health-checks.</t>
<t>version: (optional) public version of the service.</t>
<t>releaseID: (optional) in well-designed APIs, backwards-compatible changes in
the service should not update a version number. APIs usually change their
version number as infrequently as possible, to preserve stable interface.
However implementation of an API may change much more frequently, which leads
to the importance of having separate “release number” or “releaseID” that is
different from the public version of the API.</t>
<t>notes: (optional) array of notes relevant to current state of health</t>
<t>output: (optional) raw error output, in case of “fail” or “warn” states. This
field SHOULD be omitted for “pass” state.</t>
<t>details: (optional) an object representing status of sub-components of the
service in question. Please refer to the “The Details Object” section for more
information.</t>
<t>links: (optional) an array of objects containing link relations and URIs
<xref target="RFC3986"/> for external links that MAY contain more information about the
health of the endpoint. Per web-linking standards <xref target="RFC5988"/> a link relationship
SHOULD either be a common/registered one or be indicated as a URI, to avoid
name clashes. If a “self” link is provided, it MAY be used by clients to
check health via HTTP response code, as mentioned above.</t>
<t>serviceID: (optional) unique identifier of the service, in the application
scope.</t>
<t>description: (optional) human-friendly description of the service.</t>
</list></t>
</section>
<section anchor="the-details-object" title="The Details Object">
<t>The “details” object MAY have a number of unique keyes, one for each logical
sub-components. Since each sub-component may be backed by several nodes with
varying health statuses, the key points to an array of objects. In case of a
single-node sub-component (or if presence of nodes is not relevant), a
single-element array should be used as the value, for consistency.</t>
<t>The key identifying an element in the object should be a unique string within
the details section. It MAY have two parts: “{componentName}:{metricName}”, in
which case the meaning of the parts SHOULD be as follows:</t>
<t><list style="symbols">
<t>componentName: (optional) human-readable name for the component. MUST not
contain a colon, in the name, since colon is used as a separator.</t>
<t>metricName: (optional) name of the metrics that the status is reported for.
MUST not contain a colon, in the name, since colon is used as a separator and
can be one of:
<list style="symbols">
<t>Pre-defined value from this spec. Pre-defined values include:
<list style="symbols">
<t>utilization</t>
<t>responseTime</t>
<t>connections</t>
<t>uptime</t>
</list></t>
<t>A common and standard term from a well-known source such as schema.org, IANA
or microformats.</t>
<t>A URI that indicates extra semantics and processing rules that MAY be
provided by a resource at the other end of the URI. URIs do not have to be
dereferenceable, however. They are just a namespace, and the meaning of a
namespace CAN be provided by any convenient means (e.g. publishing an RFC,
Swagger document or a nicely printed book).</t>
</list></t>
</list></t>
<t>On the value eside of the equation, each “component details” object in the array
MAY have one of the following object keys:</t>
<t><list style="symbols">
<t>componentId: (optional) unique identifier of an instance of a specific
sub-component/dependency of a service. Multiple objects with the same
componentID MAY appear in the details, if they are from different nodes.</t>
<t>componentType: (optional) SHOULD be present if componentName is present. Type
of the component. Could be one of:
<list style="symbols">
<t>Pre-defined value from this spec. Pre-defined values include:
<list style="symbols">
<t>component</t>
<t>datastore</t>
<t>system</t>
</list></t>
<t>A common and standard term from a well-known source such as schema.org, IANA
or microformats.</t>
<t>A URI that indicates extra semantics and processing rules that MAY be
provided by a resource at the other end of the URI. URIs do not have to be
dereferenceable, however. They are just a namespace, and the meaning of a
namespace CAN be provided by any convenient means (e.g. publishing an RFC,
Swagger document or a nicely printed book).</t>
</list></t>
<t>metricValue: (optional) could be any valid JSON value, such as: string, number,
object, array or literal.</t>
<t>metricUnit: (optional) SHOULD be present if metricValue is present. Could be
one of:
<list style="symbols">
<t>A common and standard term from a well-known source such as schema.org, IANA,
microformats, or a standards document such as <xref target="RFC3339"/>.</t>
<t>A URI that indicates extra semantics and processing rules that MAY be
provided by a resource at the other end of the URI. URIs do not have to be
dereferenceable, however. They are just a namespace, and the meaning of a
namespace CAN be provided by any convenient means (e.g. publishing an RFC,
Swagger document or a nicely printed book).</t>
</list></t>
<t>time: the date-time, in ISO8601 format, at which the reading of the
metricValue was recorded. This assumes that the value can be cached and the
reading typically doesn’t happen in real time, for performance and scalability
purposes.</t>
<t>output: (optional) has the exact same meaning as the top-level “output”
element, but for the sub-component.</t>
<t>links: (optional) has the exact same meaning as the top-level “output”
element, but for the sub-component.</t>
</list></t>
</section>
<section anchor="example-output" title="Example Output">
<figure><artwork><![CDATA[
GET /health HTTP/1.1
Host: example.org
Accept: application/health+json
HTTP/1.1 200 OK
Content-Type: application/health+json
Cache-Control: max-age=3600
Connection: close
{
"status": "pass",
"version": "1",
"releaseID": "1.2.2",
"notes": [""],
"output": "",
"serviceID": "f03e522f-1f44-4062-9b55-9587f91c9c41",
"description": "health of authz service",
"details": {
"cassandra:responseTime": [
{
"componentId": "dfd6cf2b-1b6e-4412-a0b8-f6f7797a60d2",
"componentType": "datastore",
"metricValue": 250,
"metricUnit": "ms",
"status": "pass",
"time": "2018-01-17T03:36:48Z",
"output": ""
}
],
"cassandra:connections": [
{
"componentId": "dfd6cf2b-1b6e-4412-a0b8-f6f7797a60d2",
"type": "datastore",
"metricValue": 75,
"status": "warn",
"time": "2018-01-17T03:36:48Z",
"output": "",
"links": {
"self": "http://api.example.com/dbnode/dfd6cf2b/health"
}
}
],
"uptime": [
{
"componentType": "system",
"metricValue": 1209600.245,
"metricUnit": "s",
"status": "pass",
"time": "2018-01-17T03:36:48Z"
}
],
"cpu:utilization": [
{
"componentId": "6fd416e0-8920-410f-9c7b-c479000f7227",
"node": 1,
"componentType": "system",
"metricValue": 85,
"metricUnit": "percent",
"status": "warn",
"time": "2018-01-17T03:36:48Z",
"output": ""
},
{
"componentId": "6fd416e0-8920-410f-9c7b-c479000f7227",
"node": 2,
"componentType": "system",
"metricValue": 85,
"metricUnit": "percent",
"status": "warn",
"time": "2018-01-17T03:36:48Z",
"output": ""
}
],
"memory:utilization": [
{
"componentId": "6fd416e0-8920-410f-9c7b-c479000f7227",
"node": 1,
"componentType": "system",
"metricValue": 8.5,
"metricUnit": "GiB",
"status": "warn",
"time": "2018-01-17T03:36:48Z",
"output": ""
},
{
"componentId": "6fd416e0-8920-410f-9c7b-c479000f7227",
"node": 2,
"componentType": "system",
"metricValue": 5500,
"metricUnit": "MiB",
"status": "pass",
"time": "2018-01-17T03:36:48Z",
"output": ""
}
]
},
"links": {
"about": "http://api.example.com/about/authz",
"http://api.x.io/rel/thresholds":
"http://api.x.io/about/authz/thresholds"
}
}
]]></artwork></figure>
</section>
<section anchor="security-considerations" title="Security Considerations">
<t>Clients need to exercise care when reporting health information. Malicious
actors could use this information for orchestrating attacks. In some cases the
health check endpoints may need to be authenticated and institute role-based
access control.</t>
</section>
<section anchor="iana-considerations" title="IANA Considerations">
<section anchor="media-type-registration" title="Media Type Registration">
<t>TODO: application/health+json is being submitted for registration per
<xref target="RFC6838"/></t>
</section>
</section>
</middle>
<back>
<references title='Normative References'>
<reference anchor="RFC2119" target='https://www.rfc-editor.org/info/rfc2119'>
<front>
<title>Key words for use in RFCs to Indicate Requirement Levels</title>
<author initials='S.' surname='Bradner' fullname='S. Bradner'><organization /></author>
<date year='1997' month='March' />
<abstract><t>In many standards track documents several words are used to signify the requirements in the specification. These words are often capitalized. This document defines these words as they should be interpreted in IETF documents. This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t></abstract>
</front>
<seriesInfo name='BCP' value='14'/>
<seriesInfo name='RFC' value='2119'/>
<seriesInfo name='DOI' value='10.17487/RFC2119'/>
</reference>
<reference anchor="RFC3986" target='https://www.rfc-editor.org/info/rfc3986'>
<front>
<title>Uniform Resource Identifier (URI): Generic Syntax</title>
<author initials='T.' surname='Berners-Lee' fullname='T. Berners-Lee'><organization /></author>
<author initials='R.' surname='Fielding' fullname='R. Fielding'><organization /></author>
<author initials='L.' surname='Masinter' fullname='L. Masinter'><organization /></author>
<date year='2005' month='January' />
<abstract><t>A Uniform Resource Identifier (URI) is a compact sequence of characters that identifies an abstract or physical resource. This specification defines the generic URI syntax and a process for resolving URI references that might be in relative form, along with guidelines and security considerations for the use of URIs on the Internet. The URI syntax defines a grammar that is a superset of all valid URIs, allowing an implementation to parse the common components of a URI reference without knowing the scheme-specific requirements of every possible identifier. This specification does not define a generative grammar for URIs; that task is performed by the individual specifications of each URI scheme. [STANDARDS-TRACK]</t></abstract>
</front>
<seriesInfo name='STD' value='66'/>
<seriesInfo name='RFC' value='3986'/>
<seriesInfo name='DOI' value='10.17487/RFC3986'/>
</reference>
<reference anchor="RFC5988" target='https://www.rfc-editor.org/info/rfc5988'>
<front>
<title>Web Linking</title>
<author initials='M.' surname='Nottingham' fullname='M. Nottingham'><organization /></author>
<date year='2010' month='October' />
<abstract><t>This document specifies relation types for Web links, and defines a registry for them. It also defines the use of such links in HTTP headers with the Link header field. [STANDARDS-TRACK]</t></abstract>
</front>
<seriesInfo name='RFC' value='5988'/>
<seriesInfo name='DOI' value='10.17487/RFC5988'/>
</reference>
<reference anchor="RFC7234" target='https://www.rfc-editor.org/info/rfc7234'>
<front>
<title>Hypertext Transfer Protocol (HTTP/1.1): Caching</title>
<author initials='R.' surname='Fielding' fullname='R. Fielding' role='editor'><organization /></author>
<author initials='M.' surname='Nottingham' fullname='M. Nottingham' role='editor'><organization /></author>
<author initials='J.' surname='Reschke' fullname='J. Reschke' role='editor'><organization /></author>
<date year='2014' month='June' />
<abstract><t>The Hypertext Transfer Protocol (HTTP) is a stateless \%application- level protocol for distributed, collaborative, hypertext information systems. This document defines HTTP caches and the associated header fields that control cache behavior or indicate cacheable response messages.</t></abstract>
</front>
<seriesInfo name='RFC' value='7234'/>
<seriesInfo name='DOI' value='10.17487/RFC7234'/>
</reference>
<reference anchor="RFC8259" target='https://www.rfc-editor.org/info/rfc8259'>
<front>
<title>The JavaScript Object Notation (JSON) Data Interchange Format</title>
<author initials='T.' surname='Bray' fullname='T. Bray' role='editor'><organization /></author>
<date year='2017' month='December' />
<abstract><t>JavaScript Object Notation (JSON) is a lightweight, text-based, language-independent data interchange format. It was derived from the ECMAScript Programming Language Standard. JSON defines a small set of formatting rules for the portable representation of structured data.</t><t>This document removes inconsistencies with other specifications of JSON, repairs specification errors, and offers experience-based interoperability guidance.</t></abstract>
</front>
<seriesInfo name='STD' value='90'/>
<seriesInfo name='RFC' value='8259'/>
<seriesInfo name='DOI' value='10.17487/RFC8259'/>
</reference>
</references>
<references title='Informative References'>
<reference anchor="RFC7230" target='https://www.rfc-editor.org/info/rfc7230'>
<front>
<title>Hypertext Transfer Protocol (HTTP/1.1): Message Syntax and Routing</title>
<author initials='R.' surname='Fielding' fullname='R. Fielding' role='editor'><organization /></author>
<author initials='J.' surname='Reschke' fullname='J. Reschke' role='editor'><organization /></author>
<date year='2014' month='June' />
<abstract><t>The Hypertext Transfer Protocol (HTTP) is a stateless application-level protocol for distributed, collaborative, hypertext information systems. This document provides an overview of HTTP architecture and its associated terminology, defines the "http" and "https" Uniform Resource Identifier (URI) schemes, defines the HTTP/1.1 message syntax and parsing requirements, and describes related security concerns for implementations.</t></abstract>
</front>
<seriesInfo name='RFC' value='7230'/>
<seriesInfo name='DOI' value='10.17487/RFC7230'/>
</reference>
<reference anchor="RFC6838" target='https://www.rfc-editor.org/info/rfc6838'>
<front>
<title>Media Type Specifications and Registration Procedures</title>
<author initials='N.' surname='Freed' fullname='N. Freed'><organization /></author>
<author initials='J.' surname='Klensin' fullname='J. Klensin'><organization /></author>
<author initials='T.' surname='Hansen' fullname='T. Hansen'><organization /></author>
<date year='2013' month='January' />
<abstract><t>This document defines procedures for the specification and registration of media types for use in HTTP, MIME, and other Internet protocols. This memo documents an Internet Best Current Practice.</t></abstract>
</front>
<seriesInfo name='BCP' value='13'/>
<seriesInfo name='RFC' value='6838'/>
<seriesInfo name='DOI' value='10.17487/RFC6838'/>
</reference>
<reference anchor="RFC7231" target='https://www.rfc-editor.org/info/rfc7231'>
<front>
<title>Hypertext Transfer Protocol (HTTP/1.1): Semantics and Content</title>
<author initials='R.' surname='Fielding' fullname='R. Fielding' role='editor'><organization /></author>
<author initials='J.' surname='Reschke' fullname='J. Reschke' role='editor'><organization /></author>
<date year='2014' month='June' />
<abstract><t>The Hypertext Transfer Protocol (HTTP) is a stateless \%application- level protocol for distributed, collaborative, hypertext information systems. This document defines the semantics of HTTP/1.1 messages, as expressed by request methods, request header fields, response status codes, and response header fields, along with the payload of messages (metadata and body content) and mechanisms for content negotiation.</t></abstract>
</front>
<seriesInfo name='RFC' value='7231'/>
<seriesInfo name='DOI' value='10.17487/RFC7231'/>
</reference>
<reference anchor="RFC3339" target='https://www.rfc-editor.org/info/rfc3339'>
<front>
<title>Date and Time on the Internet: Timestamps</title>
<author initials='G.' surname='Klyne' fullname='G. Klyne'><organization /></author>
<author initials='C.' surname='Newman' fullname='C. Newman'><organization /></author>
<date year='2002' month='July' />
</front>
<seriesInfo name='RFC' value='3339'/>
<seriesInfo name='DOI' value='10.17487/RFC3339'/>
</reference>
</references>
<section anchor="acknowledgements" title="Acknowledgements">
<t>Thanks to Mike Amundsen, Erik Wilde, Justin Bachorik and Randall Randall for
their suggestions and feedback. And to Mark Nottingham for blueprint for
authoring RFCs easily.</t>
</section>
<section anchor="creating-and-serving-health-responses" title="Creating and Serving Health Responses">
<t>When making an health check endpoint available, there are a few things to keep
in mind:</t>
<t><list style="symbols">
<t>A health response endpoint is best located at a memorable and commonly-used
URI, such as “health” because it will help self-discoverability by clients.</t>
<t>Health check responses can be personalized. For example, you could advertise
different URIs, and/or different kinds of link relations, to afford different
clients access to additional health check information.</t>
<t>Health check responses must be assigned a freshness lifetime (e.g.,
“Cache-Control: max-age=3600”) so that clients can determine how long they
could cache them, to avoid overly frequent fetching and unintended DDOS-ing of
the service.</t>
<t>Custom link relation types, as well as the URIs for variables, should lead to
documentation for those constructs.</t>
</list></t>
</section>
<section anchor="consuming-health-check-responses" title="Consuming Health Check Responses">
<t>Clients might use health check responses in a variety of ways.</t>
<t>Note that the health check response is a “living” document; links from the
health check response MUST NOT be assumed to be valid beyond the freshness
lifetime of the health check response, as per HTTP’s caching model <xref target="RFC7234"/>.</t>
<t>As a result, clients ought to cache the health check response (as per
<xref target="RFC7234"/>), to avoid fetching it before every interaction (which would
otherwise be required).</t>
<t>Likewise, a client encountering a 404 (Not Found) on a link is encouraged to obtain
a fresh copy of the health check response, to assure that it is up-to-date.</t>
</section>
</back>
<!-- ##markdown-source:
H4sIAHXFtloAA+1bbXMbOXL+Pr8CRX842+FQFPXOJFfR2d61LmvLseRcXa62
tsAZUMRqOGAGM6S4Lm3dD0n+3P2SPN0NDIcStb7U7abqLucPFjkDNBrdT78C
TNM0qW1dmLF6a3RRz9Srmclu1UfjF670Rn3lqrmu1dRV6u319Qd1/uHCJ3oy
qcxynOQuK/Ucc/NKT+vUljrXlbGpXth0xuTSjMilw2GS6xoDR8P90yTDxxtX
rcfKllOXJHZRjVVdNb4eDYdnw1ECInqsvjalqXSRrFx1e1O5ZjFObs0a3/Kx
uihrU5WmTl/Tyknia13m3+nClVhkbXyysGP1h9plfYX/bJmbsu4r76q6MlOP
T+t5+FBXNsOrzM0XOnyYYzBe2bKwpfk2SXRTz1w1TlSaKPyzpQcDA/Vedutn
S1tYfiPCuKj0bWF3vMZaxtRjtb9/qI4g6vOlKRvDrzJbQxzvzUr9HruVR64p
axLSp9LWJldXNcTm+ZWZa1tAerzQv9zQtwH45ndNhZ3P6n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