Skip to content

Disable Keep-Alive to save battery #513

@fortuna

Description

@fortuna

Intra should disable Keep-Alive to avoid waking up the network device when not needed.

The dialer is created at

func MakeDialer(p Protector) *net.Dialer {

In

return d.DialContext(ctx, network, newAddress)

we should check if the connection is a TCPConn, and disable the Keep Alive with https://pkg.go.dev/net#TCPConn.SetKeepAlive.

Metadata

Metadata

Assignees

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