policies

package
v0.8.37 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 26, 2025 License: Apache-2.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ErrPrepareForEvalCode = "meshkit-11144"
	ErrEvalCode           = "meshkit-11145"
)

Variables

View Source
var SyncRelationship sync.Mutex

Functions

func ErrEval

func ErrEval(err error) error

func ErrPrepareForEval

func ErrPrepareForEval(err error) error

Types

type ComponentUpdateActionPayload

type ComponentUpdateActionPayload struct {
	Id    string      `json:"id"`
	Value interface{} `json:"value"`
	Path  []string    `json:"path"`
}

type CustomPrintHook

type CustomPrintHook struct {
	Messages []string
}

CustomPrintHook implements the print.Hook interface

func (*CustomPrintHook) Print

func (h *CustomPrintHook) Print(ctx print.Context, s string) error

Print captures print messages from policy evaluation Implements print.Hook interface

type Rego

type Rego struct {
	// contains filtered or unexported fields
}

func NewRegoInstance

func NewRegoInstance(policyDir string, regManager *registry.RegistryManager) (*Rego, error)

func (*Rego) RegoPolicyHandler

func (r *Rego) RegoPolicyHandler(designFile pattern.PatternFile, regoQueryString string, relationshipsToEvalaute ...string) (pattern.EvaluationResponse, error)

RegoPolicyHandler takes the required inputs and run the query against all the policy files provided

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL