feat: add agent acks to in-memory coordinator (#12786)

When an agent receives a node, it responds with an ACK which is relayed
to the client. After the client receives the ACK, it's allowed to begin
pinging.
This commit is contained in:
Colin Adler
2024-04-10 17:15:33 -05:00
committed by GitHub
parent 9cf2358114
commit e801e878ba
13 changed files with 879 additions and 123 deletions
+4 -1
View File
@@ -88,7 +88,6 @@ type Options struct {
// falling back. This is useful for misbehaving proxies that prevent
// fallback due to odd behavior, like Azure App Proxy.
DERPForceWebSockets bool
// BlockEndpoints specifies whether P2P endpoints are blocked.
// If so, only DERPs can establish connections.
BlockEndpoints bool
@@ -311,6 +310,10 @@ type Conn struct {
trafficStats *connstats.Statistics
}
func (c *Conn) SetTunnelDestination(id uuid.UUID) {
c.configMaps.setTunnelDestination(id)
}
func (c *Conn) GetBlockEndpoints() bool {
return c.configMaps.getBlockEndpoints() && c.nodeUpdater.getBlockEndpoints()
}