php - Google API 卷曲超时
问题描述
从昨天开始,我在日志中看到了很多这样的错误:
Operation timed out after 100001 milliseconds with 0 bytes received
File: /var/www/html/vendor/google/apiclient/src/Google/IO/Curl.php(126)
Trace: #0 /var/www/html/vendor/google/apiclient/src/Google/IO/Abstract.php(136): Google_IO_Curl->executeRequest(Object(Google_Http_Request))
#1 /var/www/html/vendor/google/apiclient/src/Google/Http/REST.php(60): Google_IO_Abstract->makeRequest(Object(Google_Http_Request))
#2 /var/www/html/vendor/google/apiclient/src/Google/Task/Runner.php(174): Google_Http_REST::doExecute(Object(Google_Client), Object(Google_Http_Request))
#3 /var/www/html/vendor/google/apiclient/src/Google/Http/REST.php(46): Google_Task_Runner->run()
#4 /var/www/html/vendor/google/apiclient/src/Google/Client.php(593): Google_Http_REST::execute(Object(Google_Client), Object(Google_Http_Request))
#5 /var/www/html/vendor/google/apiclient/src/Google/Service/Resource.php(240): Google_Client->execute(Object(Google_Http_Request))
#6 /var/www/html/vendor/google/apiclient/src/Google/Service/Drive.php(2000): Google_Service_Resource->call('update', Array, 'Google_Service_...')
#7 /var/www/html/app/lib/GoogleDriveHelper.php(185): Google_Service_Drive_Files_Resource->update('1jbLDzGVNNNigA...', Object(Google_Service_Drive_DriveFile), Array)
#8 /var/www/html/app/lib/GoogleDriveHelper.php(131): GoogleDriveHelper->updateFile('1jbLDzGVNNNigA...', '/tmp/tr-filesUI...')
#9 /var/www/html/app/lib/GoogleDriveHelper.php(66): GoogleDriveHelper->createOrUpdateFileOnce('Folder/Photo_...', 'Filen...', '/tmp/tr-filesUI...', 'image/jpeg', '', true)
#10 /var/www/html/app/jobs/worker/taskresult-photo-upload-to-gdrive.php(170): GoogleDriveHelper->createOrUpdateFile('Folder/Photo_...', 'Filen...', '/tmp/tr-filesUI...', 'image/jpeg')
#11 [internal function]: upload_photos_to_gdrive(Object(GearmanJob), NULL)
#12 /var/www/html/app/jobs/uploads-worker.php(5): GearmanWorker->work()
我已尝试检查Google 服务状态页面,但没有报告任何问题。我以前从未见过这种异常发生过,我这边也没有任何改变。
我应该注意到这种情况很少发生,有时 Google Drive 会响应 502 错误状态代码和以下消息:
<p>The server encountered a temporary error and could not complete your request.<p>Please try again in 30 seconds. <ins>That’s all we know.</ins>
也许您一直在解决这个问题,并且可以指出我正在发生的事情的解释,这是可以预防的(如果可以的话 - 如何)或者这些问题是否在我的服务方面?
解决方案
推荐阅读
- java - 如何使用 Smack 4 解析 Muc Sub 事件包
- python - Django:如何在不重新加载页面的情况下提交表单并在同一页面上接收结果
- unity3d - 如何更改对象的中心以正确旋转?
- vb.net - 使两个组合框的输入从 csv 文件中搜索、读取和显示数据
- css - 更改传入字符串中特定单词的颜色
- algorithm - 从城市 1 到达城市 N 的最短时间
- r - 使用循环将矩阵转换为另一个矩阵
- asp.net-mvc - 在从 Swagger 2.0 到 3.0 的 swagger 更改中将整数列表发送到 API 端点
- excel - Excel:自动化 COUNTIF(基于另一个表)
- android - 如何在 request.newBuilder() 中调用 httpLoggingInterceptor