Lower timeouts.

This commit is contained in:
flash 2023-01-25 20:49:42 +00:00
parent 29c466ddf3
commit 8f38e5fd56
5 changed files with 5 additions and 5 deletions

View file

@ -35,7 +35,7 @@ final class EEPROMLookup implements \Uiharu\ILookup {
CURLOPT_TCP_FASTOPEN => true, CURLOPT_TCP_FASTOPEN => true,
CURLOPT_CONNECTTIMEOUT => 2, CURLOPT_CONNECTTIMEOUT => 2,
CURLOPT_PROTOCOLS => CURLPROTO_HTTPS, CURLOPT_PROTOCOLS => CURLPROTO_HTTPS,
CURLOPT_TIMEOUT => 5, CURLOPT_TIMEOUT => 2,
CURLOPT_USERAGENT => 'Uiharu/' . UIH_VERSION, CURLOPT_USERAGENT => 'Uiharu/' . UIH_VERSION,
CURLOPT_HTTPHEADER => [ CURLOPT_HTTPHEADER => [
'Accept: application/json', 'Accept: application/json',

View file

@ -72,7 +72,7 @@ final class NicoNicoLookup implements \Uiharu\ILookup {
CURLOPT_TCP_FASTOPEN => true, CURLOPT_TCP_FASTOPEN => true,
CURLOPT_CONNECTTIMEOUT => 2, CURLOPT_CONNECTTIMEOUT => 2,
CURLOPT_PROTOCOLS => CURLPROTO_HTTPS, CURLOPT_PROTOCOLS => CURLPROTO_HTTPS,
CURLOPT_TIMEOUT => 5, CURLOPT_TIMEOUT => 3,
CURLOPT_USERAGENT => 'Uiharu/' . UIH_VERSION, CURLOPT_USERAGENT => 'Uiharu/' . UIH_VERSION,
]); ]);
$resp = curl_exec($curl); $resp = curl_exec($curl);

View file

@ -32,7 +32,7 @@ final class TwitterLookup implements \Uiharu\ILookup {
CURLOPT_TCP_FASTOPEN => true, CURLOPT_TCP_FASTOPEN => true,
CURLOPT_CONNECTTIMEOUT => 2, CURLOPT_CONNECTTIMEOUT => 2,
CURLOPT_PROTOCOLS => CURLPROTO_HTTPS, CURLOPT_PROTOCOLS => CURLPROTO_HTTPS,
CURLOPT_TIMEOUT => 5, CURLOPT_TIMEOUT => 2,
CURLOPT_USERAGENT => 'Uiharu/' . UIH_VERSION, CURLOPT_USERAGENT => 'Uiharu/' . UIH_VERSION,
CURLOPT_HTTPHEADER => [ CURLOPT_HTTPHEADER => [
'Authorization: Bearer ' . Config::get('Twitter', 'apiToken'), 'Authorization: Bearer ' . Config::get('Twitter', 'apiToken'),

View file

@ -30,7 +30,7 @@ final class WebLookup implements \Uiharu\ILookup {
CURLOPT_CONNECTTIMEOUT => 2, CURLOPT_CONNECTTIMEOUT => 2,
CURLOPT_PROTOCOLS => CURLPROTO_HTTP | CURLPROTO_HTTPS, CURLOPT_PROTOCOLS => CURLPROTO_HTTP | CURLPROTO_HTTPS,
CURLOPT_REDIR_PROTOCOLS => CURLPROTO_HTTP | CURLPROTO_HTTPS, CURLOPT_REDIR_PROTOCOLS => CURLPROTO_HTTP | CURLPROTO_HTTPS,
CURLOPT_TIMEOUT => 5, CURLOPT_TIMEOUT => 2,
CURLOPT_DEFAULT_PROTOCOL => 'https', CURLOPT_DEFAULT_PROTOCOL => 'https',
CURLOPT_USERAGENT => 'Mozilla/5.0 (compatible) Uiharu/' . UIH_VERSION, CURLOPT_USERAGENT => 'Mozilla/5.0 (compatible) Uiharu/' . UIH_VERSION,
CURLOPT_HTTPHEADER => [ CURLOPT_HTTPHEADER => [

View file

@ -79,7 +79,7 @@ final class YouTubeLookup implements \Uiharu\ILookup {
CURLOPT_TCP_FASTOPEN => true, CURLOPT_TCP_FASTOPEN => true,
CURLOPT_CONNECTTIMEOUT => 2, CURLOPT_CONNECTTIMEOUT => 2,
CURLOPT_PROTOCOLS => CURLPROTO_HTTPS, CURLOPT_PROTOCOLS => CURLPROTO_HTTPS,
CURLOPT_TIMEOUT => 5, CURLOPT_TIMEOUT => 2,
CURLOPT_USERAGENT => 'Uiharu/' . UIH_VERSION, CURLOPT_USERAGENT => 'Uiharu/' . UIH_VERSION,
CURLOPT_HTTPHEADER => [ CURLOPT_HTTPHEADER => [
'Accept: application/json', 'Accept: application/json',