Replace router svcAddrUpdateLocks with new throttler package for code readability&reusability (#1047)
Rename svcAddrUpdateLock to Throttler and move it to the top-level directory as a package for code import.
This commit is contained in:
@@ -26,6 +26,7 @@ import (
|
||||
|
||||
"github.com/fission/fission"
|
||||
"github.com/fission/fission/crd"
|
||||
"github.com/fission/fission/throttler"
|
||||
)
|
||||
|
||||
func TestRouter(t *testing.T) {
|
||||
@@ -57,7 +58,7 @@ func TestRouter(t *testing.T) {
|
||||
timeoutExponent: 2,
|
||||
keepAlive: 30 * time.Second,
|
||||
maxRetries: 10,
|
||||
}, false, MakeUpdateLocks(30*time.Second))
|
||||
}, false, throttler.MakeThrottler(30*time.Second))
|
||||
triggerUrl := "/foo"
|
||||
triggers.triggers = append(triggers.triggers,
|
||||
crd.HTTPTrigger{
|
||||
|
||||
Reference in New Issue
Block a user