Documentation
¶
Overview ¶
Package evaluation is a reverse proxy.
It translates gRPC into RESTful JSON APIs.
Index ¶
- Constants
- Variables
- func RegisterEvaluationServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
- func RegisterEvaluationServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client EvaluationServiceClient) error
- func RegisterEvaluationServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, ...) (err error)
- func RegisterEvaluationServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server EvaluationServiceServer) error
- func RegisterEvaluationServiceServer(s grpc.ServiceRegistrar, srv EvaluationServiceServer)
- type BatchEvaluationRequest
- func (*BatchEvaluationRequest) Descriptor() ([]byte, []int)deprecated
- func (x *BatchEvaluationRequest) GetRequestId() string
- func (x *BatchEvaluationRequest) GetRequests() []*EvaluationRequest
- func (*BatchEvaluationRequest) ProtoMessage()
- func (x *BatchEvaluationRequest) ProtoReflect() protoreflect.Message
- func (x *BatchEvaluationRequest) Reset()
- func (x *BatchEvaluationRequest) SetRequestIDIfNotBlank(id string) string
- func (x *BatchEvaluationRequest) String() string
- type BatchEvaluationResponse
- func (*BatchEvaluationResponse) Descriptor() ([]byte, []int)deprecated
- func (x *BatchEvaluationResponse) GetRequestDurationMillis() float64
- func (x *BatchEvaluationResponse) GetRequestId() string
- func (x *BatchEvaluationResponse) GetResponses() []*EvaluationResponse
- func (*BatchEvaluationResponse) ProtoMessage()
- func (x *BatchEvaluationResponse) ProtoReflect() protoreflect.Message
- func (x *BatchEvaluationResponse) Reset()
- func (x *BatchEvaluationResponse) SetRequestIDIfNotBlank(id string) string
- func (x *BatchEvaluationResponse) SetTimestamps(start, end time.Time)
- func (x *BatchEvaluationResponse) String() string
- type BooleanEvaluationResponse
- func (*BooleanEvaluationResponse) Descriptor() ([]byte, []int)deprecated
- func (x *BooleanEvaluationResponse) GetEnabled() bool
- func (x *BooleanEvaluationResponse) GetReason() EvaluationReason
- func (x *BooleanEvaluationResponse) GetRequestDurationMillis() float64
- func (x *BooleanEvaluationResponse) GetRequestId() string
- func (x *BooleanEvaluationResponse) GetTimestamp() *timestamppb.Timestamp
- func (*BooleanEvaluationResponse) ProtoMessage()
- func (x *BooleanEvaluationResponse) ProtoReflect() protoreflect.Message
- func (x *BooleanEvaluationResponse) Reset()
- func (x *BooleanEvaluationResponse) SetRequestIDIfNotBlank(id string) string
- func (x *BooleanEvaluationResponse) SetTimestamps(start, end time.Time)
- func (x *BooleanEvaluationResponse) String() string
- type ErrorEvaluationReason
- func (ErrorEvaluationReason) Descriptor() protoreflect.EnumDescriptor
- func (x ErrorEvaluationReason) Enum() *ErrorEvaluationReason
- func (ErrorEvaluationReason) EnumDescriptor() ([]byte, []int)deprecated
- func (x ErrorEvaluationReason) Number() protoreflect.EnumNumber
- func (x ErrorEvaluationReason) String() string
- func (ErrorEvaluationReason) Type() protoreflect.EnumType
- type ErrorEvaluationResponse
- func (*ErrorEvaluationResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ErrorEvaluationResponse) GetFlagKey() string
- func (x *ErrorEvaluationResponse) GetNamespaceKey() string
- func (x *ErrorEvaluationResponse) GetReason() ErrorEvaluationReason
- func (*ErrorEvaluationResponse) ProtoMessage()
- func (x *ErrorEvaluationResponse) ProtoReflect() protoreflect.Message
- func (x *ErrorEvaluationResponse) Reset()
- func (x *ErrorEvaluationResponse) String() string
- type EvaluationReason
- func (EvaluationReason) Descriptor() protoreflect.EnumDescriptor
- func (x EvaluationReason) Enum() *EvaluationReason
- func (EvaluationReason) EnumDescriptor() ([]byte, []int)deprecated
- func (x EvaluationReason) Number() protoreflect.EnumNumber
- func (x EvaluationReason) String() string
- func (EvaluationReason) Type() protoreflect.EnumType
- type EvaluationRequest
- func (*EvaluationRequest) Descriptor() ([]byte, []int)deprecated
- func (x *EvaluationRequest) GetContext() map[string]string
- func (x *EvaluationRequest) GetEntityId() string
- func (x *EvaluationRequest) GetFlagKey() string
- func (x *EvaluationRequest) GetNamespaceKey() string
- func (x *EvaluationRequest) GetRequestId() string
- func (*EvaluationRequest) ProtoMessage()
- func (x *EvaluationRequest) ProtoReflect() protoreflect.Message
- func (x *EvaluationRequest) Reset()
- func (x *EvaluationRequest) SetRequestIDIfNotBlank(id string) string
- func (x *EvaluationRequest) String() string
- type EvaluationResponse
- func (*EvaluationResponse) Descriptor() ([]byte, []int)deprecated
- func (x *EvaluationResponse) GetBooleanResponse() *BooleanEvaluationResponse
- func (x *EvaluationResponse) GetErrorResponse() *ErrorEvaluationResponse
- func (x *EvaluationResponse) GetRequestDurationMillis() float64
- func (x *EvaluationResponse) GetRequestId() string
- func (m *EvaluationResponse) GetResponse() isEvaluationResponse_Response
- func (x *EvaluationResponse) GetTimestamp() *timestamppb.Timestamp
- func (x *EvaluationResponse) GetType() EvaluationResponseType
- func (x *EvaluationResponse) GetVariantResponse() *VariantEvaluationResponse
- func (*EvaluationResponse) ProtoMessage()
- func (x *EvaluationResponse) ProtoReflect() protoreflect.Message
- func (x *EvaluationResponse) Reset()
- func (x *EvaluationResponse) SetRequestIDIfNotBlank(id string) string
- func (x *EvaluationResponse) SetTimestamps(start, end time.Time)
- func (x *EvaluationResponse) String() string
- type EvaluationResponseType
- func (EvaluationResponseType) Descriptor() protoreflect.EnumDescriptor
- func (x EvaluationResponseType) Enum() *EvaluationResponseType
- func (EvaluationResponseType) EnumDescriptor() ([]byte, []int)deprecated
- func (x EvaluationResponseType) Number() protoreflect.EnumNumber
- func (x EvaluationResponseType) String() string
- func (EvaluationResponseType) Type() protoreflect.EnumType
- type EvaluationResponse_BooleanResponse
- type EvaluationResponse_ErrorResponse
- type EvaluationResponse_VariantResponse
- type EvaluationServiceClient
- type EvaluationServiceServer
- type UnimplementedEvaluationServiceServer
- func (UnimplementedEvaluationServiceServer) Batch(context.Context, *BatchEvaluationRequest) (*BatchEvaluationResponse, error)
- func (UnimplementedEvaluationServiceServer) Boolean(context.Context, *EvaluationRequest) (*BooleanEvaluationResponse, error)
- func (UnimplementedEvaluationServiceServer) Variant(context.Context, *EvaluationRequest) (*VariantEvaluationResponse, error)
- type UnsafeEvaluationServiceServer
- type VariantEvaluationResponse
- func (*VariantEvaluationResponse) Descriptor() ([]byte, []int)deprecated
- func (x *VariantEvaluationResponse) GetMatch() bool
- func (x *VariantEvaluationResponse) GetReason() EvaluationReason
- func (x *VariantEvaluationResponse) GetRequestDurationMillis() float64
- func (x *VariantEvaluationResponse) GetRequestId() string
- func (x *VariantEvaluationResponse) GetSegmentKeys() []string
- func (x *VariantEvaluationResponse) GetTimestamp() *timestamppb.Timestamp
- func (x *VariantEvaluationResponse) GetVariantAttachment() string
- func (x *VariantEvaluationResponse) GetVariantKey() string
- func (*VariantEvaluationResponse) ProtoMessage()
- func (x *VariantEvaluationResponse) ProtoReflect() protoreflect.Message
- func (x *VariantEvaluationResponse) Reset()
- func (x *VariantEvaluationResponse) SetRequestIDIfNotBlank(id string) string
- func (x *VariantEvaluationResponse) SetTimestamps(start, end time.Time)
- func (x *VariantEvaluationResponse) String() string
Constants ¶
const ( EvaluationService_Boolean_FullMethodName = "/flipt.evaluation.EvaluationService/Boolean" EvaluationService_Variant_FullMethodName = "/flipt.evaluation.EvaluationService/Variant" EvaluationService_Batch_FullMethodName = "/flipt.evaluation.EvaluationService/Batch" )
Variables ¶
var ( EvaluationReason_name = map[int32]string{ 0: "UNKNOWN_EVALUATION_REASON", 1: "FLAG_DISABLED_EVALUATION_REASON", 2: "MATCH_EVALUATION_REASON", 3: "DEFAULT_EVALUATION_REASON", } EvaluationReason_value = map[string]int32{ "UNKNOWN_EVALUATION_REASON": 0, "FLAG_DISABLED_EVALUATION_REASON": 1, "MATCH_EVALUATION_REASON": 2, "DEFAULT_EVALUATION_REASON": 3, } )
Enum value maps for EvaluationReason.
var ( ErrorEvaluationReason_name = map[int32]string{ 0: "UNKNOWN_ERROR_EVALUATION_REASON", 1: "NOT_FOUND_ERROR_EVALUATION_REASON", } ErrorEvaluationReason_value = map[string]int32{ "UNKNOWN_ERROR_EVALUATION_REASON": 0, "NOT_FOUND_ERROR_EVALUATION_REASON": 1, } )
Enum value maps for ErrorEvaluationReason.
var ( EvaluationResponseType_name = map[int32]string{ 0: "VARIANT_EVALUATION_RESPONSE_TYPE", 1: "BOOLEAN_EVALUATION_RESPONSE_TYPE", 2: "ERROR_EVALUATION_RESPONSE_TYPE", } EvaluationResponseType_value = map[string]int32{ "VARIANT_EVALUATION_RESPONSE_TYPE": 0, "BOOLEAN_EVALUATION_RESPONSE_TYPE": 1, "ERROR_EVALUATION_RESPONSE_TYPE": 2, } )
Enum value maps for EvaluationResponseType.
var EvaluationService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "flipt.evaluation.EvaluationService", HandlerType: (*EvaluationServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Boolean", Handler: _EvaluationService_Boolean_Handler, }, { MethodName: "Variant", Handler: _EvaluationService_Variant_Handler, }, { MethodName: "Batch", Handler: _EvaluationService_Batch_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "evaluation/evaluation.proto", }
EvaluationService_ServiceDesc is the grpc.ServiceDesc for EvaluationService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_evaluation_evaluation_proto protoreflect.FileDescriptor
Functions ¶
func RegisterEvaluationServiceHandler ¶
func RegisterEvaluationServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error
RegisterEvaluationServiceHandler registers the http handlers for service EvaluationService to "mux". The handlers forward requests to the grpc endpoint over "conn".
func RegisterEvaluationServiceHandlerClient ¶
func RegisterEvaluationServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client EvaluationServiceClient) error
RegisterEvaluationServiceHandlerClient registers the http handlers for service EvaluationService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "EvaluationServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "EvaluationServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "EvaluationServiceClient" to call the correct interceptors.
func RegisterEvaluationServiceHandlerFromEndpoint ¶
func RegisterEvaluationServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)
RegisterEvaluationServiceHandlerFromEndpoint is same as RegisterEvaluationServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.
func RegisterEvaluationServiceHandlerServer ¶
func RegisterEvaluationServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server EvaluationServiceServer) error
RegisterEvaluationServiceHandlerServer registers the http handlers for service EvaluationService to "mux". UnaryRPC :call EvaluationServiceServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterEvaluationServiceHandlerFromEndpoint instead.
func RegisterEvaluationServiceServer ¶
func RegisterEvaluationServiceServer(s grpc.ServiceRegistrar, srv EvaluationServiceServer)
Types ¶
type BatchEvaluationRequest ¶
type BatchEvaluationRequest struct { RequestId string `protobuf:"bytes,1,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` Requests []*EvaluationRequest `protobuf:"bytes,3,rep,name=requests,proto3" json:"requests,omitempty"` // contains filtered or unexported fields }
func (*BatchEvaluationRequest) Descriptor
deprecated
func (*BatchEvaluationRequest) Descriptor() ([]byte, []int)
Deprecated: Use BatchEvaluationRequest.ProtoReflect.Descriptor instead.
func (*BatchEvaluationRequest) GetRequestId ¶
func (x *BatchEvaluationRequest) GetRequestId() string
func (*BatchEvaluationRequest) GetRequests ¶
func (x *BatchEvaluationRequest) GetRequests() []*EvaluationRequest
func (*BatchEvaluationRequest) ProtoMessage ¶
func (*BatchEvaluationRequest) ProtoMessage()
func (*BatchEvaluationRequest) ProtoReflect ¶
func (x *BatchEvaluationRequest) ProtoReflect() protoreflect.Message
func (*BatchEvaluationRequest) Reset ¶
func (x *BatchEvaluationRequest) Reset()
func (*BatchEvaluationRequest) SetRequestIDIfNotBlank ¶
func (x *BatchEvaluationRequest) SetRequestIDIfNotBlank(id string) string
func (*BatchEvaluationRequest) String ¶
func (x *BatchEvaluationRequest) String() string
type BatchEvaluationResponse ¶
type BatchEvaluationResponse struct { RequestId string `protobuf:"bytes,1,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` Responses []*EvaluationResponse `protobuf:"bytes,2,rep,name=responses,proto3" json:"responses,omitempty"` RequestDurationMillis float64 `` /* 128-byte string literal not displayed */ // contains filtered or unexported fields }
func (*BatchEvaluationResponse) Descriptor
deprecated
func (*BatchEvaluationResponse) Descriptor() ([]byte, []int)
Deprecated: Use BatchEvaluationResponse.ProtoReflect.Descriptor instead.
func (*BatchEvaluationResponse) GetRequestDurationMillis ¶
func (x *BatchEvaluationResponse) GetRequestDurationMillis() float64
func (*BatchEvaluationResponse) GetRequestId ¶
func (x *BatchEvaluationResponse) GetRequestId() string
func (*BatchEvaluationResponse) GetResponses ¶
func (x *BatchEvaluationResponse) GetResponses() []*EvaluationResponse
func (*BatchEvaluationResponse) ProtoMessage ¶
func (*BatchEvaluationResponse) ProtoMessage()
func (*BatchEvaluationResponse) ProtoReflect ¶
func (x *BatchEvaluationResponse) ProtoReflect() protoreflect.Message
func (*BatchEvaluationResponse) Reset ¶
func (x *BatchEvaluationResponse) Reset()
func (*BatchEvaluationResponse) SetRequestIDIfNotBlank ¶
func (x *BatchEvaluationResponse) SetRequestIDIfNotBlank(id string) string
SetRequestIDIfNotBlank attempts to set the provided ID on the instance If the ID was blank, it returns the ID provided to this call. If the ID was not blank, it returns the ID found on the instance.
func (*BatchEvaluationResponse) SetTimestamps ¶
func (x *BatchEvaluationResponse) SetTimestamps(start, end time.Time)
SetTimestamps records the start and end times on the target instance.
func (*BatchEvaluationResponse) String ¶
func (x *BatchEvaluationResponse) String() string
type BooleanEvaluationResponse ¶
type BooleanEvaluationResponse struct { Enabled bool `protobuf:"varint,1,opt,name=enabled,proto3" json:"enabled,omitempty"` Reason EvaluationReason `protobuf:"varint,2,opt,name=reason,proto3,enum=flipt.evaluation.EvaluationReason" json:"reason,omitempty"` RequestId string `protobuf:"bytes,3,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` RequestDurationMillis float64 `` /* 128-byte string literal not displayed */ Timestamp *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=timestamp,proto3" json:"timestamp,omitempty"` // contains filtered or unexported fields }
func (*BooleanEvaluationResponse) Descriptor
deprecated
func (*BooleanEvaluationResponse) Descriptor() ([]byte, []int)
Deprecated: Use BooleanEvaluationResponse.ProtoReflect.Descriptor instead.
func (*BooleanEvaluationResponse) GetEnabled ¶
func (x *BooleanEvaluationResponse) GetEnabled() bool
func (*BooleanEvaluationResponse) GetReason ¶
func (x *BooleanEvaluationResponse) GetReason() EvaluationReason
func (*BooleanEvaluationResponse) GetRequestDurationMillis ¶
func (x *BooleanEvaluationResponse) GetRequestDurationMillis() float64
func (*BooleanEvaluationResponse) GetRequestId ¶
func (x *BooleanEvaluationResponse) GetRequestId() string
func (*BooleanEvaluationResponse) GetTimestamp ¶
func (x *BooleanEvaluationResponse) GetTimestamp() *timestamppb.Timestamp
func (*BooleanEvaluationResponse) ProtoMessage ¶
func (*BooleanEvaluationResponse) ProtoMessage()
func (*BooleanEvaluationResponse) ProtoReflect ¶
func (x *BooleanEvaluationResponse) ProtoReflect() protoreflect.Message
func (*BooleanEvaluationResponse) Reset ¶
func (x *BooleanEvaluationResponse) Reset()
func (*BooleanEvaluationResponse) SetRequestIDIfNotBlank ¶
func (x *BooleanEvaluationResponse) SetRequestIDIfNotBlank(id string) string
func (*BooleanEvaluationResponse) SetTimestamps ¶
func (x *BooleanEvaluationResponse) SetTimestamps(start, end time.Time)
func (*BooleanEvaluationResponse) String ¶
func (x *BooleanEvaluationResponse) String() string
type ErrorEvaluationReason ¶
type ErrorEvaluationReason int32
const ( ErrorEvaluationReason_UNKNOWN_ERROR_EVALUATION_REASON ErrorEvaluationReason = 0 ErrorEvaluationReason_NOT_FOUND_ERROR_EVALUATION_REASON ErrorEvaluationReason = 1 )
func (ErrorEvaluationReason) Descriptor ¶
func (ErrorEvaluationReason) Descriptor() protoreflect.EnumDescriptor
func (ErrorEvaluationReason) Enum ¶
func (x ErrorEvaluationReason) Enum() *ErrorEvaluationReason
func (ErrorEvaluationReason) EnumDescriptor
deprecated
func (ErrorEvaluationReason) EnumDescriptor() ([]byte, []int)
Deprecated: Use ErrorEvaluationReason.Descriptor instead.
func (ErrorEvaluationReason) Number ¶
func (x ErrorEvaluationReason) Number() protoreflect.EnumNumber
func (ErrorEvaluationReason) String ¶
func (x ErrorEvaluationReason) String() string
func (ErrorEvaluationReason) Type ¶
func (ErrorEvaluationReason) Type() protoreflect.EnumType
type ErrorEvaluationResponse ¶
type ErrorEvaluationResponse struct { FlagKey string `protobuf:"bytes,1,opt,name=flag_key,json=flagKey,proto3" json:"flag_key,omitempty"` NamespaceKey string `protobuf:"bytes,2,opt,name=namespace_key,json=namespaceKey,proto3" json:"namespace_key,omitempty"` Reason ErrorEvaluationReason `protobuf:"varint,3,opt,name=reason,proto3,enum=flipt.evaluation.ErrorEvaluationReason" json:"reason,omitempty"` // contains filtered or unexported fields }
func (*ErrorEvaluationResponse) Descriptor
deprecated
func (*ErrorEvaluationResponse) Descriptor() ([]byte, []int)
Deprecated: Use ErrorEvaluationResponse.ProtoReflect.Descriptor instead.
func (*ErrorEvaluationResponse) GetFlagKey ¶
func (x *ErrorEvaluationResponse) GetFlagKey() string
func (*ErrorEvaluationResponse) GetNamespaceKey ¶
func (x *ErrorEvaluationResponse) GetNamespaceKey() string
func (*ErrorEvaluationResponse) GetReason ¶
func (x *ErrorEvaluationResponse) GetReason() ErrorEvaluationReason
func (*ErrorEvaluationResponse) ProtoMessage ¶
func (*ErrorEvaluationResponse) ProtoMessage()
func (*ErrorEvaluationResponse) ProtoReflect ¶
func (x *ErrorEvaluationResponse) ProtoReflect() protoreflect.Message
func (*ErrorEvaluationResponse) Reset ¶
func (x *ErrorEvaluationResponse) Reset()
func (*ErrorEvaluationResponse) String ¶
func (x *ErrorEvaluationResponse) String() string
type EvaluationReason ¶
type EvaluationReason int32
const ( EvaluationReason_UNKNOWN_EVALUATION_REASON EvaluationReason = 0 EvaluationReason_FLAG_DISABLED_EVALUATION_REASON EvaluationReason = 1 EvaluationReason_MATCH_EVALUATION_REASON EvaluationReason = 2 EvaluationReason_DEFAULT_EVALUATION_REASON EvaluationReason = 3 )
func (EvaluationReason) Descriptor ¶
func (EvaluationReason) Descriptor() protoreflect.EnumDescriptor
func (EvaluationReason) Enum ¶
func (x EvaluationReason) Enum() *EvaluationReason
func (EvaluationReason) EnumDescriptor
deprecated
func (EvaluationReason) EnumDescriptor() ([]byte, []int)
Deprecated: Use EvaluationReason.Descriptor instead.
func (EvaluationReason) Number ¶
func (x EvaluationReason) Number() protoreflect.EnumNumber
func (EvaluationReason) String ¶
func (x EvaluationReason) String() string
func (EvaluationReason) Type ¶
func (EvaluationReason) Type() protoreflect.EnumType
type EvaluationRequest ¶
type EvaluationRequest struct { RequestId string `protobuf:"bytes,1,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` NamespaceKey string `protobuf:"bytes,2,opt,name=namespace_key,json=namespaceKey,proto3" json:"namespace_key,omitempty"` FlagKey string `protobuf:"bytes,3,opt,name=flag_key,json=flagKey,proto3" json:"flag_key,omitempty"` EntityId string `protobuf:"bytes,4,opt,name=entity_id,json=entityId,proto3" json:"entity_id,omitempty"` Context map[string]string `` /* 155-byte string literal not displayed */ // contains filtered or unexported fields }
func (*EvaluationRequest) Descriptor
deprecated
func (*EvaluationRequest) Descriptor() ([]byte, []int)
Deprecated: Use EvaluationRequest.ProtoReflect.Descriptor instead.
func (*EvaluationRequest) GetContext ¶
func (x *EvaluationRequest) GetContext() map[string]string
func (*EvaluationRequest) GetEntityId ¶
func (x *EvaluationRequest) GetEntityId() string
func (*EvaluationRequest) GetFlagKey ¶
func (x *EvaluationRequest) GetFlagKey() string
func (*EvaluationRequest) GetNamespaceKey ¶
func (x *EvaluationRequest) GetNamespaceKey() string
func (*EvaluationRequest) GetRequestId ¶
func (x *EvaluationRequest) GetRequestId() string
func (*EvaluationRequest) ProtoMessage ¶
func (*EvaluationRequest) ProtoMessage()
func (*EvaluationRequest) ProtoReflect ¶
func (x *EvaluationRequest) ProtoReflect() protoreflect.Message
func (*EvaluationRequest) Reset ¶
func (x *EvaluationRequest) Reset()
func (*EvaluationRequest) SetRequestIDIfNotBlank ¶
func (x *EvaluationRequest) SetRequestIDIfNotBlank(id string) string
SetRequestIDIfNotBlank attempts to set the provided ID on the instance If the ID was blank, it returns the ID provided to this call. If the ID was not blank, it returns the ID found on the instance.
func (*EvaluationRequest) String ¶
func (x *EvaluationRequest) String() string
type EvaluationResponse ¶
type EvaluationResponse struct { Type EvaluationResponseType `protobuf:"varint,1,opt,name=type,proto3,enum=flipt.evaluation.EvaluationResponseType" json:"type,omitempty"` // Types that are assignable to Response: // // *EvaluationResponse_BooleanResponse // *EvaluationResponse_VariantResponse // *EvaluationResponse_ErrorResponse Response isEvaluationResponse_Response `protobuf_oneof:"response"` // contains filtered or unexported fields }
func (*EvaluationResponse) Descriptor
deprecated
func (*EvaluationResponse) Descriptor() ([]byte, []int)
Deprecated: Use EvaluationResponse.ProtoReflect.Descriptor instead.
func (*EvaluationResponse) GetBooleanResponse ¶
func (x *EvaluationResponse) GetBooleanResponse() *BooleanEvaluationResponse
func (*EvaluationResponse) GetErrorResponse ¶
func (x *EvaluationResponse) GetErrorResponse() *ErrorEvaluationResponse
func (*EvaluationResponse) GetRequestDurationMillis ¶
func (x *EvaluationResponse) GetRequestDurationMillis() float64
func (*EvaluationResponse) GetRequestId ¶
func (x *EvaluationResponse) GetRequestId() string
func (*EvaluationResponse) GetResponse ¶
func (m *EvaluationResponse) GetResponse() isEvaluationResponse_Response
func (*EvaluationResponse) GetTimestamp ¶
func (x *EvaluationResponse) GetTimestamp() *timestamppb.Timestamp
func (*EvaluationResponse) GetType ¶
func (x *EvaluationResponse) GetType() EvaluationResponseType
func (*EvaluationResponse) GetVariantResponse ¶
func (x *EvaluationResponse) GetVariantResponse() *VariantEvaluationResponse
func (*EvaluationResponse) ProtoMessage ¶
func (*EvaluationResponse) ProtoMessage()
func (*EvaluationResponse) ProtoReflect ¶
func (x *EvaluationResponse) ProtoReflect() protoreflect.Message
func (*EvaluationResponse) Reset ¶
func (x *EvaluationResponse) Reset()
func (*EvaluationResponse) SetRequestIDIfNotBlank ¶
func (x *EvaluationResponse) SetRequestIDIfNotBlank(id string) string
SetRequestIDIfNotBlank attempts to set the provided ID on the instance If the ID was blank, it returns the ID provided to this call. If the ID was not blank, it returns the ID found on the instance.
func (*EvaluationResponse) SetTimestamps ¶
func (x *EvaluationResponse) SetTimestamps(start, end time.Time)
SetTimestamps records the start and end times on the target instance.
func (*EvaluationResponse) String ¶
func (x *EvaluationResponse) String() string
type EvaluationResponseType ¶
type EvaluationResponseType int32
const ( EvaluationResponseType_VARIANT_EVALUATION_RESPONSE_TYPE EvaluationResponseType = 0 EvaluationResponseType_BOOLEAN_EVALUATION_RESPONSE_TYPE EvaluationResponseType = 1 EvaluationResponseType_ERROR_EVALUATION_RESPONSE_TYPE EvaluationResponseType = 2 )
func (EvaluationResponseType) Descriptor ¶
func (EvaluationResponseType) Descriptor() protoreflect.EnumDescriptor
func (EvaluationResponseType) Enum ¶
func (x EvaluationResponseType) Enum() *EvaluationResponseType
func (EvaluationResponseType) EnumDescriptor
deprecated
func (EvaluationResponseType) EnumDescriptor() ([]byte, []int)
Deprecated: Use EvaluationResponseType.Descriptor instead.
func (EvaluationResponseType) Number ¶
func (x EvaluationResponseType) Number() protoreflect.EnumNumber
func (EvaluationResponseType) String ¶
func (x EvaluationResponseType) String() string
func (EvaluationResponseType) Type ¶
func (EvaluationResponseType) Type() protoreflect.EnumType
type EvaluationResponse_BooleanResponse ¶
type EvaluationResponse_BooleanResponse struct {
BooleanResponse *BooleanEvaluationResponse `protobuf:"bytes,2,opt,name=boolean_response,json=booleanResponse,proto3,oneof"`
}
type EvaluationResponse_ErrorResponse ¶
type EvaluationResponse_ErrorResponse struct {
ErrorResponse *ErrorEvaluationResponse `protobuf:"bytes,4,opt,name=error_response,json=errorResponse,proto3,oneof"`
}
type EvaluationResponse_VariantResponse ¶
type EvaluationResponse_VariantResponse struct {
VariantResponse *VariantEvaluationResponse `protobuf:"bytes,3,opt,name=variant_response,json=variantResponse,proto3,oneof"`
}
type EvaluationServiceClient ¶
type EvaluationServiceClient interface { Boolean(ctx context.Context, in *EvaluationRequest, opts ...grpc.CallOption) (*BooleanEvaluationResponse, error) Variant(ctx context.Context, in *EvaluationRequest, opts ...grpc.CallOption) (*VariantEvaluationResponse, error) Batch(ctx context.Context, in *BatchEvaluationRequest, opts ...grpc.CallOption) (*BatchEvaluationResponse, error) }
EvaluationServiceClient is the client API for EvaluationService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkgo.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
func NewEvaluationServiceClient ¶
func NewEvaluationServiceClient(cc grpc.ClientConnInterface) EvaluationServiceClient
type EvaluationServiceServer ¶
type EvaluationServiceServer interface { Boolean(context.Context, *EvaluationRequest) (*BooleanEvaluationResponse, error) Variant(context.Context, *EvaluationRequest) (*VariantEvaluationResponse, error) Batch(context.Context, *BatchEvaluationRequest) (*BatchEvaluationResponse, error) // contains filtered or unexported methods }
EvaluationServiceServer is the server API for EvaluationService service. All implementations must embed UnimplementedEvaluationServiceServer for forward compatibility
type UnimplementedEvaluationServiceServer ¶
type UnimplementedEvaluationServiceServer struct { }
UnimplementedEvaluationServiceServer must be embedded to have forward compatible implementations.
func (UnimplementedEvaluationServiceServer) Batch ¶
func (UnimplementedEvaluationServiceServer) Batch(context.Context, *BatchEvaluationRequest) (*BatchEvaluationResponse, error)
func (UnimplementedEvaluationServiceServer) Boolean ¶
func (UnimplementedEvaluationServiceServer) Boolean(context.Context, *EvaluationRequest) (*BooleanEvaluationResponse, error)
func (UnimplementedEvaluationServiceServer) Variant ¶
func (UnimplementedEvaluationServiceServer) Variant(context.Context, *EvaluationRequest) (*VariantEvaluationResponse, error)
type UnsafeEvaluationServiceServer ¶
type UnsafeEvaluationServiceServer interface {
// contains filtered or unexported methods
}
UnsafeEvaluationServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to EvaluationServiceServer will result in compilation errors.
type VariantEvaluationResponse ¶
type VariantEvaluationResponse struct { Match bool `protobuf:"varint,1,opt,name=match,proto3" json:"match,omitempty"` SegmentKeys []string `protobuf:"bytes,2,rep,name=segment_keys,json=segmentKeys,proto3" json:"segment_keys,omitempty"` Reason EvaluationReason `protobuf:"varint,3,opt,name=reason,proto3,enum=flipt.evaluation.EvaluationReason" json:"reason,omitempty"` VariantKey string `protobuf:"bytes,4,opt,name=variant_key,json=variantKey,proto3" json:"variant_key,omitempty"` VariantAttachment string `protobuf:"bytes,5,opt,name=variant_attachment,json=variantAttachment,proto3" json:"variant_attachment,omitempty"` RequestId string `protobuf:"bytes,6,opt,name=request_id,json=requestId,proto3" json:"request_id,omitempty"` RequestDurationMillis float64 `` /* 128-byte string literal not displayed */ Timestamp *timestamppb.Timestamp `protobuf:"bytes,8,opt,name=timestamp,proto3" json:"timestamp,omitempty"` // contains filtered or unexported fields }
func (*VariantEvaluationResponse) Descriptor
deprecated
func (*VariantEvaluationResponse) Descriptor() ([]byte, []int)
Deprecated: Use VariantEvaluationResponse.ProtoReflect.Descriptor instead.
func (*VariantEvaluationResponse) GetMatch ¶
func (x *VariantEvaluationResponse) GetMatch() bool
func (*VariantEvaluationResponse) GetReason ¶
func (x *VariantEvaluationResponse) GetReason() EvaluationReason
func (*VariantEvaluationResponse) GetRequestDurationMillis ¶
func (x *VariantEvaluationResponse) GetRequestDurationMillis() float64
func (*VariantEvaluationResponse) GetRequestId ¶
func (x *VariantEvaluationResponse) GetRequestId() string
func (*VariantEvaluationResponse) GetSegmentKeys ¶
func (x *VariantEvaluationResponse) GetSegmentKeys() []string
func (*VariantEvaluationResponse) GetTimestamp ¶
func (x *VariantEvaluationResponse) GetTimestamp() *timestamppb.Timestamp
func (*VariantEvaluationResponse) GetVariantAttachment ¶
func (x *VariantEvaluationResponse) GetVariantAttachment() string
func (*VariantEvaluationResponse) GetVariantKey ¶
func (x *VariantEvaluationResponse) GetVariantKey() string
func (*VariantEvaluationResponse) ProtoMessage ¶
func (*VariantEvaluationResponse) ProtoMessage()
func (*VariantEvaluationResponse) ProtoReflect ¶
func (x *VariantEvaluationResponse) ProtoReflect() protoreflect.Message
func (*VariantEvaluationResponse) Reset ¶
func (x *VariantEvaluationResponse) Reset()
func (*VariantEvaluationResponse) SetRequestIDIfNotBlank ¶
func (x *VariantEvaluationResponse) SetRequestIDIfNotBlank(id string) string
func (*VariantEvaluationResponse) SetTimestamps ¶
func (x *VariantEvaluationResponse) SetTimestamps(start, end time.Time)
func (*VariantEvaluationResponse) String ¶
func (x *VariantEvaluationResponse) String() string