net3

package
v0.0.0-...-7f84440 Latest Latest
Warning

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

Go to latest
Published: Nov 12, 2022 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrUnsupported = errors.New("unsupported")
	ErrNotFound    = errors.New("not found")
)

Functions

This section is empty.

Types

type Destination

type Destination struct {
	Kind      DestinationKind
	Name      string
	Namespace string
	Protocol  string
	Domain    string
	Port      int32
}

Destination is a destination for a request.

func NewDestination

func NewDestination(address, defaultNamespace string) (*Destination, error)

NewDestination creates a new destination from an address.

func (*Destination) FullPort

func (d *Destination) FullPort() string

FullPort returns the protocol and port of the destionation.

type DestinationKind

type DestinationKind string

DestinationKind is a type of destination.

const (
	DestinationKindService DestinationKind = "service"
)

type Net3

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

func New

func New(k8s kubernetes.Interface) *Net3

New creates a net3 application.

func (*Net3) AddProxy

func (n *Net3) AddProxy(namespace, serviceName, containerName, image string, port int32) error

AddProxy redeploys pods with a proxy container which logs all requests to the specified port.

func (*Net3) ListProxies

func (n *Net3) ListProxies(namespace string, allNamespaces bool, service string) error

Logs redeploys pods with a proxy container which logs all requests to the specified port.

func (*Net3) RemoveProxy

func (n *Net3) RemoveProxy(namespace, serviceName string, port int32) error

RemoveProxy removes an existing net3 proxy from a service.

func (*Net3) Topo

func (n *Net3) Topo(namespace, src, dest string) error

Topo lists the topology of a connection path.

Jump to

Keyboard shortcuts

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