-
Notifications
You must be signed in to change notification settings - Fork 0
/
fault.pb.go
342 lines (307 loc) · 15.1 KB
/
fault.pb.go
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
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: envoy/config/filter/http/fault/v2/fault.proto
package envoy_config_filter_http_fault_v2
import (
fmt "fmt"
route "github.com/altipla-consulting/envoy-api/envoy/api/v2/route"
v2 "github.com/altipla-consulting/envoy-api/envoy/config/filter/fault/v2"
_type "github.com/altipla-consulting/envoy-api/envoy/type"
_ "github.com/envoyproxy/protoc-gen-validate/validate"
types "github.com/gogo/protobuf/types"
proto "github.com/golang/protobuf/proto"
math "math"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
type FaultAbort struct {
// Types that are valid to be assigned to ErrorType:
// *FaultAbort_HttpStatus
ErrorType isFaultAbort_ErrorType `protobuf_oneof:"error_type"`
// The percentage of requests/operations/connections that will be aborted with the error code
// provided.
Percentage *_type.FractionalPercent `protobuf:"bytes,3,opt,name=percentage,proto3" json:"percentage,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *FaultAbort) Reset() { *m = FaultAbort{} }
func (m *FaultAbort) String() string { return proto.CompactTextString(m) }
func (*FaultAbort) ProtoMessage() {}
func (*FaultAbort) Descriptor() ([]byte, []int) {
return fileDescriptor_26070db6b6576d5c, []int{0}
}
func (m *FaultAbort) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_FaultAbort.Unmarshal(m, b)
}
func (m *FaultAbort) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_FaultAbort.Marshal(b, m, deterministic)
}
func (m *FaultAbort) XXX_Merge(src proto.Message) {
xxx_messageInfo_FaultAbort.Merge(m, src)
}
func (m *FaultAbort) XXX_Size() int {
return xxx_messageInfo_FaultAbort.Size(m)
}
func (m *FaultAbort) XXX_DiscardUnknown() {
xxx_messageInfo_FaultAbort.DiscardUnknown(m)
}
var xxx_messageInfo_FaultAbort proto.InternalMessageInfo
type isFaultAbort_ErrorType interface {
isFaultAbort_ErrorType()
}
type FaultAbort_HttpStatus struct {
HttpStatus uint32 `protobuf:"varint,2,opt,name=http_status,json=httpStatus,proto3,oneof"`
}
func (*FaultAbort_HttpStatus) isFaultAbort_ErrorType() {}
func (m *FaultAbort) GetErrorType() isFaultAbort_ErrorType {
if m != nil {
return m.ErrorType
}
return nil
}
func (m *FaultAbort) GetHttpStatus() uint32 {
if x, ok := m.GetErrorType().(*FaultAbort_HttpStatus); ok {
return x.HttpStatus
}
return 0
}
func (m *FaultAbort) GetPercentage() *_type.FractionalPercent {
if m != nil {
return m.Percentage
}
return nil
}
// XXX_OneofWrappers is for the internal use of the proto package.
func (*FaultAbort) XXX_OneofWrappers() []interface{} {
return []interface{}{
(*FaultAbort_HttpStatus)(nil),
}
}
// [#next-free-field: 14]
type HTTPFault struct {
// If specified, the filter will inject delays based on the values in the
// object.
Delay *v2.FaultDelay `protobuf:"bytes,1,opt,name=delay,proto3" json:"delay,omitempty"`
// If specified, the filter will abort requests based on the values in
// the object. At least *abort* or *delay* must be specified.
Abort *FaultAbort `protobuf:"bytes,2,opt,name=abort,proto3" json:"abort,omitempty"`
// Specifies the name of the (destination) upstream cluster that the
// filter should match on. Fault injection will be restricted to requests
// bound to the specific upstream cluster.
UpstreamCluster string `protobuf:"bytes,3,opt,name=upstream_cluster,json=upstreamCluster,proto3" json:"upstream_cluster,omitempty"`
// Specifies a set of headers that the filter should match on. The fault
// injection filter can be applied selectively to requests that match a set of
// headers specified in the fault filter config. The chances of actual fault
// injection further depend on the value of the :ref:`percentage
// <envoy_api_field_config.filter.http.fault.v2.FaultAbort.percentage>` field.
// The filter will check the request's headers against all the specified
// headers in the filter config. A match will happen if all the headers in the
// config are present in the request with the same values (or based on
// presence if the *value* field is not in the config).
Headers []*route.HeaderMatcher `protobuf:"bytes,4,rep,name=headers,proto3" json:"headers,omitempty"`
// Faults are injected for the specified list of downstream hosts. If this
// setting is not set, faults are injected for all downstream nodes.
// Downstream node name is taken from :ref:`the HTTP
// x-envoy-downstream-service-node
// <config_http_conn_man_headers_downstream-service-node>` header and compared
// against downstream_nodes list.
DownstreamNodes []string `protobuf:"bytes,5,rep,name=downstream_nodes,json=downstreamNodes,proto3" json:"downstream_nodes,omitempty"`
// The maximum number of faults that can be active at a single time via the configured fault
// filter. Note that because this setting can be overridden at the route level, it's possible
// for the number of active faults to be greater than this value (if injected via a different
// route). If not specified, defaults to unlimited. This setting can be overridden via
// `runtime <config_http_filters_fault_injection_runtime>` and any faults that are not injected
// due to overflow will be indicated via the `faults_overflow
// <config_http_filters_fault_injection_stats>` stat.
//
// .. attention::
// Like other :ref:`circuit breakers <arch_overview_circuit_break>` in Envoy, this is a fuzzy
// limit. It's possible for the number of active faults to rise slightly above the configured
// amount due to the implementation details.
MaxActiveFaults *types.UInt32Value `protobuf:"bytes,6,opt,name=max_active_faults,json=maxActiveFaults,proto3" json:"max_active_faults,omitempty"`
// The response rate limit to be applied to the response body of the stream. When configured,
// the percentage can be overridden by the :ref:`fault.http.rate_limit.response_percent
// <config_http_filters_fault_injection_runtime>` runtime key.
//
// .. attention::
// This is a per-stream limit versus a connection level limit. This means that concurrent streams
// will each get an independent limit.
ResponseRateLimit *v2.FaultRateLimit `protobuf:"bytes,7,opt,name=response_rate_limit,json=responseRateLimit,proto3" json:"response_rate_limit,omitempty"`
// The runtime key to override the :ref:`default <config_http_filters_fault_injection_runtime>`
// runtime. The default is: fault.http.delay.fixed_delay_percent
DelayPercentRuntime string `protobuf:"bytes,8,opt,name=delay_percent_runtime,json=delayPercentRuntime,proto3" json:"delay_percent_runtime,omitempty"`
// The runtime key to override the :ref:`default <config_http_filters_fault_injection_runtime>`
// runtime. The default is: fault.http.abort.abort_percent
AbortPercentRuntime string `protobuf:"bytes,9,opt,name=abort_percent_runtime,json=abortPercentRuntime,proto3" json:"abort_percent_runtime,omitempty"`
// The runtime key to override the :ref:`default <config_http_filters_fault_injection_runtime>`
// runtime. The default is: fault.http.delay.fixed_duration_ms
DelayDurationRuntime string `protobuf:"bytes,10,opt,name=delay_duration_runtime,json=delayDurationRuntime,proto3" json:"delay_duration_runtime,omitempty"`
// The runtime key to override the :ref:`default <config_http_filters_fault_injection_runtime>`
// runtime. The default is: fault.http.abort.http_status
AbortHttpStatusRuntime string `protobuf:"bytes,11,opt,name=abort_http_status_runtime,json=abortHttpStatusRuntime,proto3" json:"abort_http_status_runtime,omitempty"`
// The runtime key to override the :ref:`default <config_http_filters_fault_injection_runtime>`
// runtime. The default is: fault.http.max_active_faults
MaxActiveFaultsRuntime string `protobuf:"bytes,12,opt,name=max_active_faults_runtime,json=maxActiveFaultsRuntime,proto3" json:"max_active_faults_runtime,omitempty"`
// The runtime key to override the :ref:`default <config_http_filters_fault_injection_runtime>`
// runtime. The default is: fault.http.rate_limit.response_percent
ResponseRateLimitPercentRuntime string `protobuf:"bytes,13,opt,name=response_rate_limit_percent_runtime,json=responseRateLimitPercentRuntime,proto3" json:"response_rate_limit_percent_runtime,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *HTTPFault) Reset() { *m = HTTPFault{} }
func (m *HTTPFault) String() string { return proto.CompactTextString(m) }
func (*HTTPFault) ProtoMessage() {}
func (*HTTPFault) Descriptor() ([]byte, []int) {
return fileDescriptor_26070db6b6576d5c, []int{1}
}
func (m *HTTPFault) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_HTTPFault.Unmarshal(m, b)
}
func (m *HTTPFault) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_HTTPFault.Marshal(b, m, deterministic)
}
func (m *HTTPFault) XXX_Merge(src proto.Message) {
xxx_messageInfo_HTTPFault.Merge(m, src)
}
func (m *HTTPFault) XXX_Size() int {
return xxx_messageInfo_HTTPFault.Size(m)
}
func (m *HTTPFault) XXX_DiscardUnknown() {
xxx_messageInfo_HTTPFault.DiscardUnknown(m)
}
var xxx_messageInfo_HTTPFault proto.InternalMessageInfo
func (m *HTTPFault) GetDelay() *v2.FaultDelay {
if m != nil {
return m.Delay
}
return nil
}
func (m *HTTPFault) GetAbort() *FaultAbort {
if m != nil {
return m.Abort
}
return nil
}
func (m *HTTPFault) GetUpstreamCluster() string {
if m != nil {
return m.UpstreamCluster
}
return ""
}
func (m *HTTPFault) GetHeaders() []*route.HeaderMatcher {
if m != nil {
return m.Headers
}
return nil
}
func (m *HTTPFault) GetDownstreamNodes() []string {
if m != nil {
return m.DownstreamNodes
}
return nil
}
func (m *HTTPFault) GetMaxActiveFaults() *types.UInt32Value {
if m != nil {
return m.MaxActiveFaults
}
return nil
}
func (m *HTTPFault) GetResponseRateLimit() *v2.FaultRateLimit {
if m != nil {
return m.ResponseRateLimit
}
return nil
}
func (m *HTTPFault) GetDelayPercentRuntime() string {
if m != nil {
return m.DelayPercentRuntime
}
return ""
}
func (m *HTTPFault) GetAbortPercentRuntime() string {
if m != nil {
return m.AbortPercentRuntime
}
return ""
}
func (m *HTTPFault) GetDelayDurationRuntime() string {
if m != nil {
return m.DelayDurationRuntime
}
return ""
}
func (m *HTTPFault) GetAbortHttpStatusRuntime() string {
if m != nil {
return m.AbortHttpStatusRuntime
}
return ""
}
func (m *HTTPFault) GetMaxActiveFaultsRuntime() string {
if m != nil {
return m.MaxActiveFaultsRuntime
}
return ""
}
func (m *HTTPFault) GetResponseRateLimitPercentRuntime() string {
if m != nil {
return m.ResponseRateLimitPercentRuntime
}
return ""
}
func init() {
proto.RegisterType((*FaultAbort)(nil), "envoy.config.filter.http.fault.v2.FaultAbort")
proto.RegisterType((*HTTPFault)(nil), "envoy.config.filter.http.fault.v2.HTTPFault")
}
func init() {
proto.RegisterFile("envoy/config/filter/http/fault/v2/fault.proto", fileDescriptor_26070db6b6576d5c)
}
var fileDescriptor_26070db6b6576d5c = []byte{
// 624 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x93, 0x5f, 0x6e, 0xd3, 0x40,
0x10, 0xc6, 0x71, 0xd3, 0xa6, 0xed, 0x9a, 0xaa, 0x8d, 0x0b, 0xc5, 0x44, 0x50, 0xd2, 0xf2, 0x62,
0x10, 0x5d, 0x4b, 0x2e, 0x2f, 0x08, 0x01, 0xaa, 0x5b, 0x55, 0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