Documentation ¶
Index ¶
- type Evaluator
- type Server
- func (s *Server) AllowsNamespaceScopedAuthentication(ctx context.Context) bool
- func (s *Server) Batch(ctx context.Context, b *rpcevaluation.BatchEvaluationRequest) (*rpcevaluation.BatchEvaluationResponse, error)
- func (s *Server) Boolean(ctx context.Context, r *rpcevaluation.EvaluationRequest) (*rpcevaluation.BooleanEvaluationResponse, error)
- func (s *Server) RegisterGRPC(server *grpc.Server)
- func (s *Server) Variant(ctx context.Context, r *rpcevaluation.EvaluationRequest) (*rpcevaluation.VariantEvaluationResponse, error)
- type Storer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Evaluator ¶
type Evaluator struct {
// contains filtered or unexported fields
}
Evaluator is an evaluator for legacy flag evaluations.
func NewEvaluator ¶
NewEvaluator is the constructor for an Evaluator.
type Server ¶
type Server struct { evaluation.UnimplementedEvaluationServiceServer // contains filtered or unexported fields }
Server serves the Flipt evaluate v2 gRPC Server.
func (*Server) AllowsNamespaceScopedAuthentication ¶ added in v1.31.0
func (*Server) Batch ¶
func (s *Server) Batch(ctx context.Context, b *rpcevaluation.BatchEvaluationRequest) (*rpcevaluation.BatchEvaluationResponse, error)
Batch takes in a list of *evaluation.EvaluationRequest and returns their respective responses.
func (*Server) Boolean ¶
func (s *Server) Boolean(ctx context.Context, r *rpcevaluation.EvaluationRequest) (*rpcevaluation.BooleanEvaluationResponse, error)
Boolean evaluates a request for a boolean flag and entity.
func (*Server) RegisterGRPC ¶
RegisterGRPC registers the EvaluateServer onto the provided gRPC Server.
func (*Server) Variant ¶
func (s *Server) Variant(ctx context.Context, r *rpcevaluation.EvaluationRequest) (*rpcevaluation.VariantEvaluationResponse, error)
Variant evaluates a request for a multi-variate flag and entity. It adapts the 'v2' evaluation API and proxies the request to the 'v1' evaluation API.
type Storer ¶
type Storer interface { GetFlag(ctx context.Context, namespaceKey, key string) (*flipt.Flag, error) GetEvaluationRules(ctx context.Context, namespaceKey string, flagKey string) ([]*storage.EvaluationRule, error) GetEvaluationDistributions(ctx context.Context, ruleID string) ([]*storage.EvaluationDistribution, error) GetEvaluationRollouts(ctx context.Context, namespaceKey, flagKey string) ([]*storage.EvaluationRollout, error) }
Storer is the minimal abstraction for interacting with the storage layer for evaluation.
Click to show internal directories.
Click to hide internal directories.