Documentation ¶
Index ¶
- Variables
- type CelExpression
- func (*CelExpression) Descriptor() ([]byte, []int)deprecated
- func (x *CelExpression) GetCelExprChecked() *expr.CheckedExpr
- func (x *CelExpression) GetCelExprParsed() *expr.ParsedExpr
- func (x *CelExpression) GetCheckedExpr() *v1alpha1.CheckedExprdeprecated
- func (m *CelExpression) GetExprSpecifier() isCelExpression_ExprSpecifier
- func (x *CelExpression) GetParsedExpr() *v1alpha1.ParsedExprdeprecated
- func (*CelExpression) ProtoMessage()
- func (x *CelExpression) ProtoReflect() protoreflect.Message
- func (x *CelExpression) Reset()
- func (x *CelExpression) String() string
- type CelExpression_CheckedExpr
- type CelExpression_ParsedExpr
- type CelExtractString
- func (*CelExtractString) Descriptor() ([]byte, []int)deprecated
- func (x *CelExtractString) GetDefaultValue() *wrapperspb.StringValue
- func (x *CelExtractString) GetExprExtract() *CelExpression
- func (*CelExtractString) ProtoMessage()
- func (x *CelExtractString) ProtoReflect() protoreflect.Message
- func (x *CelExtractString) Reset()
- func (x *CelExtractString) String() string
- type DoubleRange
- type Int32Range
- type Int64Range
- type TypedStruct
- func (*TypedStruct) Descriptor() ([]byte, []int)deprecated
- func (x *TypedStruct) GetTypeUrl() string
- func (x *TypedStruct) GetValue() *structpb.Struct
- func (*TypedStruct) ProtoMessage()
- func (x *TypedStruct) ProtoReflect() protoreflect.Message
- func (x *TypedStruct) Reset()
- func (x *TypedStruct) String() string
Constants ¶
This section is empty.
Variables ¶
var File_xds_type_v3_cel_proto protoreflect.FileDescriptor
var File_xds_type_v3_range_proto protoreflect.FileDescriptor
var File_xds_type_v3_typed_struct_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type CelExpression ¶
type CelExpression struct { // Types that are assignable to ExprSpecifier: // // *CelExpression_ParsedExpr // *CelExpression_CheckedExpr ExprSpecifier isCelExpression_ExprSpecifier `protobuf_oneof:"expr_specifier"` // Parsed expression in abstract syntax tree (AST) form. // // If “cel_expr_checked“ is set, this field is not used. CelExprParsed *expr.ParsedExpr `protobuf:"bytes,3,opt,name=cel_expr_parsed,json=celExprParsed,proto3" json:"cel_expr_parsed,omitempty"` // Parsed expression in abstract syntax tree (AST) form that has been successfully type checked. // // If set, takes precedence over “cel_expr_parsed“. CelExprChecked *expr.CheckedExpr `protobuf:"bytes,4,opt,name=cel_expr_checked,json=celExprChecked,proto3" json:"cel_expr_checked,omitempty"` // contains filtered or unexported fields }
Either parsed or checked representation of the `Common Expression Language <https://github.com/google/cel-spec>`_ (CEL) program.
func (*CelExpression) Descriptor
deprecated
func (*CelExpression) Descriptor() ([]byte, []int)
Deprecated: Use CelExpression.ProtoReflect.Descriptor instead.
func (*CelExpression) GetCelExprChecked ¶
func (x *CelExpression) GetCelExprChecked() *expr.CheckedExpr
func (*CelExpression) GetCelExprParsed ¶
func (x *CelExpression) GetCelExprParsed() *expr.ParsedExpr
func (*CelExpression) GetCheckedExpr
deprecated
func (x *CelExpression) GetCheckedExpr() *v1alpha1.CheckedExpr
Deprecated: Marked as deprecated in xds/type/v3/cel.proto.
func (*CelExpression) GetExprSpecifier ¶
func (m *CelExpression) GetExprSpecifier() isCelExpression_ExprSpecifier
func (*CelExpression) GetParsedExpr
deprecated
func (x *CelExpression) GetParsedExpr() *v1alpha1.ParsedExpr
Deprecated: Marked as deprecated in xds/type/v3/cel.proto.
func (*CelExpression) ProtoMessage ¶
func (*CelExpression) ProtoMessage()
func (*CelExpression) ProtoReflect ¶
func (x *CelExpression) ProtoReflect() protoreflect.Message
func (*CelExpression) Reset ¶
func (x *CelExpression) Reset()
func (*CelExpression) String ¶
func (x *CelExpression) String() string
type CelExpression_CheckedExpr ¶
type CelExpression_CheckedExpr struct { // Parsed expression in abstract syntax tree (AST) form that has been successfully type checked. // // Deprecated -- use “cel_expr_checked“ field instead. // If “cel_expr_parsed“ or “cel_expr_checked“ is set, this field is not used. // // Deprecated: Marked as deprecated in xds/type/v3/cel.proto. CheckedExpr *v1alpha1.CheckedExpr `protobuf:"bytes,2,opt,name=checked_expr,json=checkedExpr,proto3,oneof"` }
type CelExpression_ParsedExpr ¶
type CelExpression_ParsedExpr struct { // Parsed expression in abstract syntax tree (AST) form. // // Deprecated -- use “cel_expr_parsed“ field instead. // If “cel_expr_parsed“ or “cel_expr_checked“ is set, this field is not used. // // Deprecated: Marked as deprecated in xds/type/v3/cel.proto. ParsedExpr *v1alpha1.ParsedExpr `protobuf:"bytes,1,opt,name=parsed_expr,json=parsedExpr,proto3,oneof"` }
type CelExtractString ¶
type CelExtractString struct { // The CEL expression used to extract a string from the CEL environment. // the "subject string") that should be replaced. ExprExtract *CelExpression `protobuf:"bytes,1,opt,name=expr_extract,json=exprExtract,proto3" json:"expr_extract,omitempty"` // If CEL expression evaluates to an error, this value is be returned to the caller. // If not set, the error is propagated to the caller. DefaultValue *wrapperspb.StringValue `protobuf:"bytes,2,opt,name=default_value,json=defaultValue,proto3" json:"default_value,omitempty"` // contains filtered or unexported fields }
Extracts a string by evaluating a `Common Expression Language <https://github.com/google/cel-spec>`_ (CEL) expression against the standardized set of :ref:`HTTP attributes <arch_overview_attributes>`.
.. attention::
Besides CEL evaluation raising an error explicitly, CEL program returning a type other than the ``string``, or not returning anything, are considered an error as well.
[#comment:TODO(sergiitk): When implemented, add the extension tag.]
func (*CelExtractString) Descriptor
deprecated
func (*CelExtractString) Descriptor() ([]byte, []int)
Deprecated: Use CelExtractString.ProtoReflect.Descriptor instead.
func (*CelExtractString) GetDefaultValue ¶
func (x *CelExtractString) GetDefaultValue() *wrapperspb.StringValue
func (*CelExtractString) GetExprExtract ¶
func (x *CelExtractString) GetExprExtract() *CelExpression
func (*CelExtractString) ProtoMessage ¶
func (*CelExtractString) ProtoMessage()
func (*CelExtractString) ProtoReflect ¶
func (x *CelExtractString) ProtoReflect() protoreflect.Message
func (*CelExtractString) Reset ¶
func (x *CelExtractString) Reset()
func (*CelExtractString) String ¶
func (x *CelExtractString) String() string
type DoubleRange ¶
type DoubleRange struct { // start of the range (inclusive) Start float64 `protobuf:"fixed64,1,opt,name=start,proto3" json:"start,omitempty"` // end of the range (exclusive) End float64 `protobuf:"fixed64,2,opt,name=end,proto3" json:"end,omitempty"` // contains filtered or unexported fields }
Specifies the double start and end of the range using half-open interval semantics [start, end).
func (*DoubleRange) Descriptor
deprecated
func (*DoubleRange) Descriptor() ([]byte, []int)
Deprecated: Use DoubleRange.ProtoReflect.Descriptor instead.
func (*DoubleRange) GetEnd ¶
func (x *DoubleRange) GetEnd() float64
func (*DoubleRange) GetStart ¶
func (x *DoubleRange) GetStart() float64
func (*DoubleRange) ProtoMessage ¶
func (*DoubleRange) ProtoMessage()
func (*DoubleRange) ProtoReflect ¶
func (x *DoubleRange) ProtoReflect() protoreflect.Message
func (*DoubleRange) Reset ¶
func (x *DoubleRange) Reset()
func (*DoubleRange) String ¶
func (x *DoubleRange) String() string
type Int32Range ¶
type Int32Range struct { // start of the range (inclusive) Start int32 `protobuf:"varint,1,opt,name=start,proto3" json:"start,omitempty"` // end of the range (exclusive) End int32 `protobuf:"varint,2,opt,name=end,proto3" json:"end,omitempty"` // contains filtered or unexported fields }
Specifies the int32 start and end of the range using half-open interval semantics [start, end).
func (*Int32Range) Descriptor
deprecated
func (*Int32Range) Descriptor() ([]byte, []int)
Deprecated: Use Int32Range.ProtoReflect.Descriptor instead.
func (*Int32Range) GetEnd ¶
func (x *Int32Range) GetEnd() int32
func (*Int32Range) GetStart ¶
func (x *Int32Range) GetStart() int32
func (*Int32Range) ProtoMessage ¶
func (*Int32Range) ProtoMessage()
func (*Int32Range) ProtoReflect ¶
func (x *Int32Range) ProtoReflect() protoreflect.Message
func (*Int32Range) Reset ¶
func (x *Int32Range) Reset()
func (*Int32Range) String ¶
func (x *Int32Range) String() string
type Int64Range ¶
type Int64Range struct { // start of the range (inclusive) Start int64 `protobuf:"varint,1,opt,name=start,proto3" json:"start,omitempty"` // end of the range (exclusive) End int64 `protobuf:"varint,2,opt,name=end,proto3" json:"end,omitempty"` // contains filtered or unexported fields }
Specifies the int64 start and end of the range using half-open interval semantics [start, end).
func (*Int64Range) Descriptor
deprecated
func (*Int64Range) Descriptor() ([]byte, []int)
Deprecated: Use Int64Range.ProtoReflect.Descriptor instead.
func (*Int64Range) GetEnd ¶
func (x *Int64Range) GetEnd() int64
func (*Int64Range) GetStart ¶
func (x *Int64Range) GetStart() int64
func (*Int64Range) ProtoMessage ¶
func (*Int64Range) ProtoMessage()
func (*Int64Range) ProtoReflect ¶
func (x *Int64Range) ProtoReflect() protoreflect.Message
func (*Int64Range) Reset ¶
func (x *Int64Range) Reset()
func (*Int64Range) String ¶
func (x *Int64Range) String() string
type TypedStruct ¶
type TypedStruct struct { // A URL that uniquely identifies the type of the serialize protocol buffer message. // This has same semantics and format described in google.protobuf.Any: // https://github.com/protocolbuffers/protobuf/blob/master/src/google/protobuf/any.proto TypeUrl string `protobuf:"bytes,1,opt,name=type_url,json=typeUrl,proto3" json:"type_url,omitempty"` // A JSON representation of the above specified type. Value *structpb.Struct `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` // contains filtered or unexported fields }
A TypedStruct contains an arbitrary JSON serialized protocol buffer message with a URL that describes the type of the serialized message. This is very similar to google.protobuf.Any, instead of having protocol buffer binary, this employs google.protobuf.Struct as value.
This message is intended to be embedded inside Any, so it shouldn't be directly referred from other UDPA messages.
When packing an opaque extension config, packing the expected type into Any is preferred wherever possible for its efficiency. TypedStruct should be used only if a proto descriptor is not available, for example if:
- A control plane sends opaque message that is originally from external source in human readable format such as JSON or YAML.
- The control plane doesn't have the knowledge of the protocol buffer schema hence it cannot serialize the message in protocol buffer binary format.
- The DPLB doesn't have have the knowledge of the protocol buffer schema its plugin or extension uses. This has to be indicated in the DPLB capability negotiation.
When a DPLB receives a TypedStruct in Any, it should: - Check if the type_url of the TypedStruct matches the type the extension expects. - Convert value to the type described in type_url and perform validation.
TODO(lizan): Figure out how TypeStruct should be used with DPLB extensions that doesn't link protobuf descriptor with DPLB itself, (e.g. gRPC LB Plugin, Envoy WASM extensions).
func (*TypedStruct) Descriptor
deprecated
func (*TypedStruct) Descriptor() ([]byte, []int)
Deprecated: Use TypedStruct.ProtoReflect.Descriptor instead.
func (*TypedStruct) GetTypeUrl ¶
func (x *TypedStruct) GetTypeUrl() string
func (*TypedStruct) GetValue ¶
func (x *TypedStruct) GetValue() *structpb.Struct
func (*TypedStruct) ProtoMessage ¶
func (*TypedStruct) ProtoMessage()
func (*TypedStruct) ProtoReflect ¶
func (x *TypedStruct) ProtoReflect() protoreflect.Message
func (*TypedStruct) Reset ¶
func (x *TypedStruct) Reset()
func (*TypedStruct) String ¶
func (x *TypedStruct) String() string