Skip to content

Commit

Permalink
update the default value of transport.tcpMuxKeepaliveInterval (#4231)
Browse files Browse the repository at this point in the history
  • Loading branch information
fatedier committed May 21, 2024
1 parent f0442d0 commit 301515d
Show file tree
Hide file tree
Showing 6 changed files with 9 additions and 5 deletions.
4 changes: 4 additions & 0 deletions Release.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
### Fixes

* Fixed an issue where HTTP/2 was not enabled for https2http and https2https plugins.

### Changes

* Updated the default value of `transport.tcpMuxKeepaliveInterval` from 60 to 30.
2 changes: 1 addition & 1 deletion conf/frpc_full_example.toml
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ transport.poolCount = 5

# Specify keep alive interval for tcp mux.
# only valid if tcpMux is enabled.
# transport.tcpMuxKeepaliveInterval = 60
# transport.tcpMuxKeepaliveInterval = 30

# Communication protocol used to connect to server
# supports tcp, kcp, quic, websocket and wss now, default is tcp
Expand Down
2 changes: 1 addition & 1 deletion conf/frps_full_example.toml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ transport.maxPoolCount = 5

# Specify keep alive interval for tcp mux.
# only valid if tcpMux is true.
# transport.tcpMuxKeepaliveInterval = 60
# transport.tcpMuxKeepaliveInterval = 30

# tcpKeepalive specifies the interval between keep-alive probes for an active network connection between frpc and frps.
# If negative, keep-alive probes are disabled.
Expand Down
2 changes: 1 addition & 1 deletion pkg/config/v1/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ func (c *ClientTransportConfig) Complete() {
c.ProxyURL = util.EmptyOr(c.ProxyURL, os.Getenv("http_proxy"))
c.PoolCount = util.EmptyOr(c.PoolCount, 1)
c.TCPMux = util.EmptyOr(c.TCPMux, lo.ToPtr(true))
c.TCPMuxKeepaliveInterval = util.EmptyOr(c.TCPMuxKeepaliveInterval, 60)
c.TCPMuxKeepaliveInterval = util.EmptyOr(c.TCPMuxKeepaliveInterval, 30)
if lo.FromPtr(c.TCPMux) {
// If TCPMux is enabled, heartbeat of application layer is unnecessary because we can rely on heartbeat in tcpmux.
c.HeartbeatInterval = util.EmptyOr(c.HeartbeatInterval, -1)
Expand Down
2 changes: 1 addition & 1 deletion pkg/config/v1/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ type ServerTransportConfig struct {

func (c *ServerTransportConfig) Complete() {
c.TCPMux = util.EmptyOr(c.TCPMux, lo.ToPtr(true))
c.TCPMuxKeepaliveInterval = util.EmptyOr(c.TCPMuxKeepaliveInterval, 60)
c.TCPMuxKeepaliveInterval = util.EmptyOr(c.TCPMuxKeepaliveInterval, 30)
c.TCPKeepAlive = util.EmptyOr(c.TCPKeepAlive, 7200)
c.MaxPoolCount = util.EmptyOr(c.MaxPoolCount, 5)
if lo.FromPtr(c.TCPMux) {
Expand Down
2 changes: 1 addition & 1 deletion pkg/util/version/version.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@

package version

var version = "0.58.0"
var version = "0.58.1"

func Full() string {
return version
Expand Down

0 comments on commit 301515d

Please sign in to comment.