mirror of
https://gitea.com/gitea/act_runner.git
synced 2026-07-22 02:37:45 +00:00
fix: reduce idle runner polling by default
Raise the default idle fetch backoff ceiling to reduce steady-state FetchTask traffic from idle runner fleets while keeping the value configurable for installations that need faster idle polling. Fixes: https://gitea.com/gitea/runner/issues/762 Co-Authored-By: GPT-5 Codex <codex@openai.com>
This commit is contained in:
@@ -48,6 +48,12 @@ func TestLoadDefault_DefaultsWorkdirCleanupAge(t *testing.T) {
|
||||
assert.Equal(t, 10*time.Minute, cfg.Runner.IdleCleanupInterval)
|
||||
}
|
||||
|
||||
func TestLoadDefault_DefaultsIdleFetchBackoffMax(t *testing.T) {
|
||||
cfg, err := LoadDefault("")
|
||||
require.NoError(t, err)
|
||||
assert.Equal(t, time.Minute, cfg.Runner.FetchIntervalMax)
|
||||
}
|
||||
|
||||
func TestLoadDefault_UsesConfiguredWorkdirCleanupAge(t *testing.T) {
|
||||
dir := t.TempDir()
|
||||
path := filepath.Join(dir, "config.yaml")
|
||||
|
||||
Reference in New Issue
Block a user