proxy

package
v0.0.0-...-e9f4c3e Latest Latest
Warning

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

Go to latest
Published: Dec 26, 2024 License: Apache-2.0 Imports: 27 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

Functions

This section is empty.

Types

type Cache

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

func (*Cache) GetCacheBySvcID

func (c *Cache) GetCacheBySvcID(svcID string) ([]*proxycache.SvcLB, []*proxycache.Backend, []string)

type IPPort

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

func NewIPPort

func NewIPPort(ip string, pro corev1.Protocol, port int32) *IPPort

func (IPPort) String

func (i IPPort) String() string

type IPSetCtrl

type IPSetCtrl struct {
	client.Client
	TCPSet ipset.IPSet
	UDPSet ipset.IPSet
	LBSet  ipset.IPSet
	// contains filtered or unexported fields
}

func (*IPSetCtrl) CreateOrUpdate

func (p *IPSetCtrl) CreateOrUpdate(svc *corev1.Service) error

func (*IPSetCtrl) Delete

func (p *IPSetCtrl) Delete(svc types.NamespacedName) error

func (*IPSetCtrl) Reconcile

func (p *IPSetCtrl) Reconcile(ctx context.Context, req ctrl.Request) (ctrl.Result, error)

func (*IPSetCtrl) SetupWithManager

func (p *IPSetCtrl) SetupWithManager(mgr ctrl.Manager) error

func (*IPSetCtrl) Sync

func (p *IPSetCtrl) Sync(ctx context.Context) error

type PortType

type PortType string

type Reconciler

type Reconciler struct {
	client.Client
	Scheme *runtime.Scheme
	DpMgr  *datapath.DpManager

	LocalNode string
	ProxyAll  bool

	SyncChan chan event.GenericEvent

	Cache
	// contains filtered or unexported fields
}

Reconciler watch Service related resource and implement Service

func (*Reconciler) GetCache

func (r *Reconciler) GetCache() *Cache

func (*Reconciler) ReconcileService

func (r *Reconciler) ReconcileService(ctx context.Context, req ctrl.Request) (ctrl.Result, error)

ReconcileService receive Service from work queue

func (*Reconciler) ReconcileServicePort

func (r *Reconciler) ReconcileServicePort(ctx context.Context, req ctrl.Request) (ctrl.Result, error)

ReconcileSvcPort receive servicePort from work queue

func (*Reconciler) ReconcileSync

func (r *Reconciler) ReconcileSync(_ context.Context, req ctrl.Request) (ctrl.Result, error)

ReconcileSync receive proxySuncEvent from work queue

func (*Reconciler) SetupWithManager

func (r *Reconciler) SetupWithManager(mgr ctrl.Manager) error

SetupWithManager add service controller and servicePort controller to mgr

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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