mirror of
https://github.com/fatedier/frp.git
synced 2026-05-15 08:05:49 -06:00
[GH-ISSUE #3270] [Feature Request] 希望可以自行设定 frpc 最大超时时间(maxDelayTime) #2622
Labels
No labels
In Progress
WIP
WaitingForInfo
bug
doc
duplicate
easy
enhancement
future
help wanted
invalid
lifecycle/stale
need-issue-template
need-usage-help
no plan
proposal
pull-request
question
todo
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: github-starred/frp#2622
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @suiahae on GitHub (Jan 26, 2023).
Original GitHub issue: https://github.com/fatedier/frp/issues/3270
Describe the feature request
目前 frpc 最大超时时间(maxDelayTime)在代码 client/service.go#L171 中被设为 20s 且无法通过配置文件更改。
某些网络环境下,客户端与服务器间会出现长达数小时的断线,此时 20s 就显得有些短了。
Describe alternatives you've considered
No response
Affected area
@Becods commented on GitHub (Jan 26, 2023):
login_fail_exit = false,frpc将会在与frps丢失连接之后等待frps再次可用并自动连接@suiahae commented on GitHub (Jan 27, 2023):
“frps再次可用”的确定,需要frpc向frps不停的发送请求吗?间隔时间呢
@Becods commented on GitHub (Jan 28, 2023):
0eecab06c1/client/service.go (L135-L140)@suiahae commented on GitHub (Jan 28, 2023):
抱歉,是我没表达清楚。
某些情况下断连后,frpc会不断尝试连接frps,等待时间会从1s倍增至上限maxDelayTime(20s),此后会间隔maxDelayTime(20s)尝试 reconnect 。
我希望可以在配置文件中调整maxDelayTime,以免重连过于频繁。
@fatedier commented on GitHub (Jan 29, 2023):
不倾向于暴露这个配置,你描述的场景
某些网络环境下,客户端与服务器间会出现长达数小时的断线,此时 20s 就显得有些短了。和重试延迟没有太大的关系。重试本身没有什么成本,延迟会影响到恢复的时间,这个值不期望会被调整的很大。@suiahae commented on GitHub (Jan 30, 2023):
以20s的间隔重试,不会给fprc侧设备(CPU、内存、网口、路由器、交换机)带来性能和资源的压力吗?
如果这样,那这个功能确实没必要,我也能放心了
@xqzr commented on GitHub (Feb 4, 2023):
就一个 TCP SYN
能有什么@github-actions[bot] commented on GitHub (Mar 7, 2023):
Issues go stale after 30d of inactivity. Stale issues rot after an additional 7d of inactivity and eventually close.
@github-actions[bot] commented on GitHub (Mar 7, 2023):
Issues go stale after 30d of inactivity. Stale issues rot after an additional 7d of inactivity and eventually close.