/
health_check_event.proto
88 lines (64 loc) · 2.29 KB
/
health_check_event.proto
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
syntax = "proto3";
package envoy.data.core.v2alpha;
import "envoy/api/v2/core/address.proto";
import "google/protobuf/timestamp.proto";
import "udpa/annotations/status.proto";
import "validate/validate.proto";
option java_package = "io.envoyproxy.envoy.data.core.v2alpha";
option java_outer_classname = "HealthCheckEventProto";
option java_multiple_files = true;
option (udpa.annotations.file_status).package_version_status = FROZEN;
// [#protodoc-title: Health check logging events]
// :ref:`Health check logging <arch_overview_health_check_logging>`.
enum HealthCheckFailureType {
ACTIVE = 0;
PASSIVE = 1;
NETWORK = 2;
}
enum HealthCheckerType {
HTTP = 0;
TCP = 1;
GRPC = 2;
REDIS = 3;
}
// [#next-free-field: 10]
message HealthCheckEvent {
HealthCheckerType health_checker_type = 1 [(validate.rules).enum = {defined_only: true}];
api.v2.core.Address host = 2;
string cluster_name = 3 [(validate.rules).string = {min_bytes: 1}];
oneof event {
option (validate.required) = true;
// Host ejection.
HealthCheckEjectUnhealthy eject_unhealthy_event = 4;
// Host addition.
HealthCheckAddHealthy add_healthy_event = 5;
// Host failure.
HealthCheckFailure health_check_failure_event = 7;
// Healthy host became degraded.
DegradedHealthyHost degraded_healthy_host = 8;
// A degraded host returned to being healthy.
NoLongerDegradedHost no_longer_degraded_host = 9;
}
// Timestamp for event.
google.protobuf.Timestamp timestamp = 6;
}
message HealthCheckEjectUnhealthy {
// The type of failure that caused this ejection.
HealthCheckFailureType failure_type = 1 [(validate.rules).enum = {defined_only: true}];
}
message HealthCheckAddHealthy {
// Whether this addition is the result of the first ever health check on a host, in which case
// the configured :ref:`healthy threshold <envoy_api_field_core.HealthCheck.healthy_threshold>`
// is bypassed and the host is immediately added.
bool first_check = 1;
}
message HealthCheckFailure {
// The type of failure that caused this event.
HealthCheckFailureType failure_type = 1 [(validate.rules).enum = {defined_only: true}];
// Whether this event is the result of the first ever health check on a host.
bool first_check = 2;
}
message DegradedHealthyHost {
}
message NoLongerDegradedHost {
}