mapping

package
v0.7.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ClusterCache

type ClusterCache interface {
	ListServices(name string) []*corev1.Service
	GetHub(name string) *v1alpha2.Hub
	GetHubGateway(hubName string, forHub string) v1alpha2.HubSpecGateway
	GetIdentity(name string) string
	Clientset(name string) kubernetes.Interface
	LoadPortPeer(importHubName string, cluster, namespace, name string, ports []services.MappingPort)
	GetPortPeer(importHubName string, cluster, namespace, name string, port int32) int32
	RegistryServiceCallback(exportHubName, importHubName string, cb func())
	UnregistryServiceCallback(exportHubName, importHubName string)
}

type MappingController

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

func NewMappingController

func NewMappingController(conf MappingControllerConfig) *MappingController

func (*MappingController) Close

func (d *MappingController) Close()

func (*MappingController) SetRoutes

func (d *MappingController) SetRoutes(rules []*v1alpha2.Route)

func (*MappingController) Start

func (d *MappingController) Start(ctx context.Context) error

func (*MappingController) Sync

func (d *MappingController) Sync()

func (*MappingController) Way added in v0.4.0

func (d *MappingController) Way() []string

type MappingControllerConfig

type MappingControllerConfig struct {
	Namespace     string
	ExportHubName string
	ImportHubName string
	ClusterCache  ClusterCache
	Logger        logr.Logger
}

Jump to

Keyboard shortcuts

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