Skip to content

Server's PeerConnectionCheckInterval not used in CheckPeerEndpoints #1234

Description

@EC2E-Gaulupeau

Hi,
It seems that the CheckPeerEndpoints function doesn't use the server specified PeerConnectionCheckInterval, causing it to only use the default value of 15 seconds.

PeerLocalEndpointConnTicker = time.NewTicker(PeerConnectionCheckInterval)

This should be like in watchPeerConnections

server := config.GetServer(config.CurrServer)
	if server == nil {
		return
	}
	if server.PeerConnectionCheckInterval != "" {
		sec, err := strconv.Atoi(server.PeerConnectionCheckInterval)
		if err == nil && sec > 0 {
			networking.PeerConnectionCheckInterval = time.Duration(sec) * time.Second
		}
	}
	autoRelayConnTicker = time.NewTicker(networking.PeerConnectionCheckInterval)
	defer autoRelayConnTicker.Stop()

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions