Versions in this module Expand all Collapse all v2 v2.12.0 Feb 12, 2025 v2.11.0 Nov 12, 2024 Changes in this version + const SecretIdent + const SelfIdent + var MapType = cel.MapType(cel.StringType, cel.StringType) + var StringType = cel.StringType + func AllowedOutputTypes() []*cel.Type + func CheckOutputTypeAllowed(ast *cel.Ast, allowed ...*cel.Type) error + func NewEnv(resource reflect.Type) (*cel.Env, error) + func ParseStructTag(field reflect.StructField) string + func RegisterEvaluator(e ExpressionEvaluator) + type CompilationResult struct + AST *cel.Ast + Program cel.Program + func Compile(env *cel.Env, expression string) (*CompilationResult, error) + type EnvCache struct + func NewEnvCache(metrics asometrics.CEL, log logr.Logger, ...) *EnvCache + func (c *EnvCache) Get(resource reflect.Type) (*cel.Env, error) + func (c *EnvCache) Start() + func (c *EnvCache) Stop() + type ExpressionEvaluator interface + Check func(expression string, self any) (*cel.Type, error) + CompileAndRun func(expression string, self any, secret map[string]string) (*ExpressionResult, error) + FindSecretUsage func(expression string, self any) (set.Set[string], error) + Start func() + Stop func() + func Evaluator() ExpressionEvaluator + func NewExpressionEvaluator(opts ...ExpressionEvaluatorOption) (ExpressionEvaluator, error) + type ExpressionEvaluatorOption func(e *expressionEvaluator) (*expressionEvaluator, error) + func Cache(cache ProgramCacher) ExpressionEvaluatorOption + func Log(log logr.Logger) ExpressionEvaluatorOption + func Metrics(metrics asometrics.CEL) ExpressionEvaluatorOption + type ExpressionResult struct + Value string + Values map[string]string + type ProgramCache struct + func NewProgramCache(envCache *EnvCache, metrics asometrics.CEL, log logr.Logger, ...) *ProgramCache + func (c *ProgramCache) Get(resource reflect.Type, expression string) (*CompilationResult, error) + func (c *ProgramCache) Start() + func (c *ProgramCache) Stop() + type ProgramCacher interface + Get func(resource reflect.Type, expression string) (*CompilationResult, error) + Start func() + Stop func() + type UnCache struct + func NewUnCache(newEnv func(resource reflect.Type) (*cel.Env, error), ...) *UnCache + func (c *UnCache) Get(resource reflect.Type, expression string) (*CompilationResult, error) + func (c *UnCache) Start() + func (c *UnCache) Stop()