rlptools

package
v0.11.0 Latest Latest
Warning

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

Go to latest
Published: Oct 2, 2024 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ApplyOverrides added in v0.10.0

func ApplyOverrides(topology *kuadrantgatewayapi.Topology, gateway *gatewayapiv1.Gateway) (*kuadrantgatewayapi.Topology, error)

ApplyOverrides applies the overrides defined in the RateLimitPolicies attached to the gateway policies for a given gateway, and returns a new topology with all policies overridden as applicable.

func Equal added in v0.4.0

func Equal(a, b RateLimitList) bool

func LimitadorRateLimitsFromRLP added in v0.4.0

func LimitadorRateLimitsFromRLP(rlp *kuadrantv1beta2.RateLimitPolicy) []limitadorv1alpha1.RateLimit

LimitadorRateLimitsFromRLP converts rate limits from a Kuadrant RateLimitPolicy into a list of Limitador rate limit objects

func LimitsNameFromRLP added in v0.5.0

func LimitsNameFromRLP(rlp *kuadrantv1beta2.RateLimitPolicy) string

Types

type RateLimitIndex added in v0.4.0

type RateLimitIndex struct {
	orderedmap.OrderedMap[RateLimitIndexKey, RateLimitList]
}

RateLimitIndex stores RateLimitLists by key

func NewRateLimitIndex added in v0.4.0

func NewRateLimitIndex() *RateLimitIndex

NewRateLimitIndex builds an index to manage sets of rate limits, organized by key

func (*RateLimitIndex) Set added in v0.4.0

func (l *RateLimitIndex) Set(key RateLimitIndexKey, rateLimits RateLimitList)

func (*RateLimitIndex) ToRateLimits added in v0.4.0

func (l *RateLimitIndex) ToRateLimits() RateLimitList

type RateLimitIndexKey added in v0.4.0

type RateLimitIndexKey struct {
	RateLimitPolicyKey types.NamespacedName
	GatewayKey         types.NamespacedName
}

type RateLimitList added in v0.4.0

type RateLimitList []limitadorv1alpha1.RateLimit

func (RateLimitList) Len added in v0.4.0

func (l RateLimitList) Len() int

func (RateLimitList) Less added in v0.4.0

func (l RateLimitList) Less(i, j int) bool

func (RateLimitList) Swap added in v0.4.0

func (l RateLimitList) Swap(i, j int)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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