turn

package
v0.20.5 Latest Latest
Warning

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

Go to latest
Published: Jul 31, 2023 License: Apache-2.0 Imports: 27 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// PeerSignalCh - channel to recieve peer signals
	PeerSignalCh = make(chan nm_models.Signal, 50)

	// LastHandShakeThreshold - threshold for considering inactive connection
	LastHandShakeThreshold = time.Minute * 3

	ResetCh = make(chan struct{}, 2)
)

Functions

func DissolvePeerConnections added in v0.20.0

func DissolvePeerConnections()

DissolvePeerConnections - notifies all peers to disconnect from using turn.

func Init

func Init(ctx context.Context, wg *sync.WaitGroup, turnCfgs []ncconfig.TurnConfig)

Init - start's the turn client for all the present turn configs

func SignalPeer

func SignalPeer(serverName string, signal nm_models.Signal) error

SignalPeer - signals the peer with host's turn relay endpoint

func WatchPeerConnections added in v0.20.0

func WatchPeerConnections(ctx context.Context, waitg *sync.WaitGroup)

WatchPeerConnections - periodically watches peer connections. if connection is bad, host will signal peers to use turn

func WatchPeerSignals

func WatchPeerSignals(ctx context.Context, wg *sync.WaitGroup)

WatchPeerSignals - processes the peer signals for any turn updates from peers

Types

This section is empty.

Jump to

Keyboard shortcuts

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