features

package
v1.23.1 Latest Latest
Warning

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

Go to latest
Published: Apr 17, 2023 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Overview

TODO: (shance) this file should ideally be combined with backends/features

This file contains functionality and constants for the L7-ILB feature Since this also currently affects backend resources (since they are alpha-regional instead of ga-global), this feature is also included in pkg/backends/features.go

Index

Constants

View Source
const (
	FeatureL7ILB = "L7ILB"
)

Variables

View Source
var ErrSubnetNotFound = errors.New("active subnet not found")
View Source
var GAResourceVersions = NewResourceVersions()

Functions

func ILBSubnetSourceRange

func ILBSubnetSourceRange(cloud *gce.Cloud, region string) (string, error)

ILBSubnetSourceRange gets Subnet source range for ILB TODO: (shance) refactor to use filter

func L7ILBScope

func L7ILBScope() meta.KeyType

L7ILBScope is a helper to get the scope of L7-ILB

func ScopeFromIngress

func ScopeFromIngress(ing *v1.Ingress) meta.KeyType

TODO: (shance) refactor scope to be per-resource ScopeFromIngress returns the required scope of features for an Ingress

Types

type ResourceVersions

type ResourceVersions struct {
	UrlMap           meta.Version
	ForwardingRule   meta.Version
	TargetHttpProxy  meta.Version
	TargetHttpsProxy meta.Version
	SslCertificate   meta.Version

	// This is *only* used for backend annotations
	// TODO(shance): find a way to remove these
	BackendService meta.Version
	HealthCheck    meta.Version
}

ResourceVersions allows you to define all the versions required for each resource for a feature.

func L7ILBVersions

func L7ILBVersions() *ResourceVersions

L7ILBVersions is a helper to get the version of L7-ILB

func NewResourceVersions

func NewResourceVersions() *ResourceVersions

func VersionsFromIngress

func VersionsFromIngress(ing *v1.Ingress) *ResourceVersions

VersionsFromIngress returns a ResourceVersions struct containing all of the resources per version

Jump to

Keyboard shortcuts

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