proxy

package
v1.0.14 Latest Latest
Warning

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

Go to latest
Published: Dec 13, 2023 License: Apache-2.0 Imports: 18 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NSMConnectionMonitor added in v1.0.14

func NSMConnectionMonitor(ctx context.Context, name string, monitorConnectionClient networkservice.MonitorConnectionClient)

NSMConnectionMonitor - NSMConnectionMonitor monitors NSM connection events to keep track of and log important changes. Currently, monitors connections this proxy is part of. TODO: check if it could be made more generic or better integrated with proxy (to act upon certain events)

Types

type Proxy

type Proxy struct {
	Bridge networking.Bridge

	Subnets    map[ipamAPI.IPFamily]*ipamAPI.Subnet
	IpamClient ipamAPI.IpamClient
	// contains filtered or unexported fields
}

Proxy -

func NewProxy

func NewProxy(conduit *nspAPI.Conduit, nodeName string, ipamClient ipamAPI.IpamClient, ipFamily string, netUtils networking.Utils) *Proxy

NewProxy -

func (*Proxy) InterfaceCreated

func (p *Proxy) InterfaceCreated(intf networking.Iface)

InterfaceCreated -

func (*Proxy) InterfaceDeleted

func (p *Proxy) InterfaceDeleted(intf networking.Iface)

InterfaceDeleted - Note: Not called on TAPA close because the interface normally is not available to get the index. While kernel originated interface delete events are ignored by default.

func (*Proxy) SetIPContext

func (p *Proxy) SetIPContext(ctx context.Context, conn *networkservice.Connection, interfaceType networking.InterfaceType) error

SetIPContext XXX: What should we do about new connection establishment requests that fail, and thus allocated IP addresses might be leaked if the originating NSC gives up for some reason? On the other hand, would there by any unwanted side-effects of calling UnsetIPContext() from ipcontext Server/Client when Request to establish a new connection fails? NSM retry clients like fullMeshClient clones the request on each new try, thus won't cache any assigned IPs. However, NSM heal with reselect seems weird, as it keeps Closing and re-requeting the connection including the old IPs until it succeeds to reconnect or the "user" closes the connection. Thus, due to heal (with reconnect) the IPs might get updated in the NSC case, if someone happanned to allocat them between two reconnect attempts. This doesn't seem to be a problem, as it should update the connection accordingly. Based on the above, IMHO it would make sense releasing allocated IPs by ipcontext Server/Client upon unsuccesful Requests where NSM connection was not established. In the server case though, it's unlikely that the Request would fail at the proxy.

func (*Proxy) SetVIPs

func (p *Proxy) SetVIPs(vips []string)

func (*Proxy) UnsetIPContext added in v0.6.0

func (p *Proxy) UnsetIPContext(ctx context.Context, conn *networkservice.Connection, interfaceType networking.InterfaceType) error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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