Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit e71fdfa

Browse files
committed
Set the ban call timeout to 10 seconds
1 parent 2beb47b commit e71fdfa

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

Model/PurgeCache.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,8 @@ public function sendPurgeRequest($tagsPattern)
6262
'uriStem' => '/state?banExpression=' . urlencode('obj.http.X-Magento-Tags ~ ' . $tagsPattern)
6363
]);
6464

65-
$info = $this->aperture->executeAuthRequest($uri, 'POST', []);
65+
$timeout = 10;
66+
$info = $this->aperture->executeAuthRequest($uri, 'POST', [], $timeout);
6667
if ($info['http_code'] != 200) {
6768
$this->logger->execute('Error executing purge: ' . $tagsPattern . ', Error Message: ' . $info['body_content']);
6869
return false;

0 commit comments

Comments
 (0)