logs

package
v0.57.0 Latest Latest
Warning

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

Go to latest
Published: Sep 28, 2023 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GeneratePolicy

func GeneratePolicy(ruleCounts int, ruleHits int) string

GeneratePolicy generates a policy for use in Decision Log e2e tests. The `ruleCounts` determine how many total rules to generate, and the `ruleHits` are the number of them that will be evaluated. This is keyed off of the `input.hit` boolean value.

func RunDecisionLoggerBenchmark

func RunDecisionLoggerBenchmark(b *testing.B, rt *e2e.TestRuntime)

RunDecisionLoggerBenchmark runs a benchmark for decision logs with a pre-configured test runtime

Types

type TestLogServer

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

TestLogServer implements the decision log endpoint for e2e testing.

func (*TestLogServer) Start

func (t *TestLogServer) Start()

Start the test server listening on a random port.

func (*TestLogServer) Stop

func (t *TestLogServer) Stop()

Stop the test server. There is a 5 second graceful shutdown period and then it will be forcefully stopped.

func (*TestLogServer) URL

func (t *TestLogServer) URL() string

URL string representation for the current server. Requires that the server has already been started.

Jump to

Keyboard shortcuts

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