Reduce akamai purger interval in integration tests (#4277)
and reduce the verify_akamai_purge deadline/sleep to match the much smaller interval.
This commit is contained in:
parent
acc44498d1
commit
0a16b5f57d
|
|
@ -1,7 +1,7 @@
|
||||||
{
|
{
|
||||||
"akamaiPurger": {
|
"akamaiPurger": {
|
||||||
"debugAddr": ":9666",
|
"debugAddr": ":9666",
|
||||||
"purgeInterval": "1s",
|
"purgeInterval": "1ms",
|
||||||
"baseURL": "http://localhost:6789",
|
"baseURL": "http://localhost:6789",
|
||||||
"clientToken": "its-a-token",
|
"clientToken": "its-a-token",
|
||||||
"clientSecret": "its-a-secret",
|
"clientSecret": "its-a-secret",
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
{
|
{
|
||||||
"akamaiPurger": {
|
"akamaiPurger": {
|
||||||
"debugAddr": ":9666",
|
"debugAddr": ":9666",
|
||||||
"purgeInterval": "10s",
|
"purgeInterval": "1ms",
|
||||||
"baseURL": "http://localhost:6789",
|
"baseURL": "http://localhost:6789",
|
||||||
"clientToken": "its-a-token",
|
"clientToken": "its-a-token",
|
||||||
"clientSecret": "its-a-secret",
|
"clientSecret": "its-a-secret",
|
||||||
|
|
|
||||||
|
|
@ -129,9 +129,9 @@ def reset_akamai_purges():
|
||||||
requests.post("http://localhost:6789/debug/reset-purges")
|
requests.post("http://localhost:6789/debug/reset-purges")
|
||||||
|
|
||||||
def verify_akamai_purge():
|
def verify_akamai_purge():
|
||||||
deadline = time.time() + 10
|
deadline = time.time() + 0.25
|
||||||
while True:
|
while True:
|
||||||
time.sleep(0.25)
|
time.sleep(0.05)
|
||||||
if time.time() > deadline:
|
if time.time() > deadline:
|
||||||
raise Exception("Timed out waiting for Akamai purge")
|
raise Exception("Timed out waiting for Akamai purge")
|
||||||
response = requests.get("http://localhost:6789/debug/get-purges")
|
response = requests.get("http://localhost:6789/debug/get-purges")
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue