mirror of
https://github.com/woodchen-ink/proxy-go.git
synced 2025-07-18 16:41:54 +08:00
优化仪表板页面的指标获取频率,将定时器间隔从1000毫秒调整为3000毫秒,以减少请求频率并提高性能。
This commit is contained in:
parent
e98b2c3efe
commit
9c2bc25bfa
@ -98,7 +98,7 @@ export default function DashboardPage() {
|
|||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
fetchMetrics()
|
fetchMetrics()
|
||||||
const interval = setInterval(fetchMetrics, 1000)
|
const interval = setInterval(fetchMetrics, 3000)
|
||||||
return () => clearInterval(interval)
|
return () => clearInterval(interval)
|
||||||
}, [fetchMetrics])
|
}, [fetchMetrics])
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user