Google任务API:403禁止,超出服务限制 [英] Google Tasks API: 403 Forbidden, Serving Limit Exceeded

查看:372
本文介绍了Google任务API:403禁止,超出服务限制的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好Google Tasks API小组,

自几天前我们开始取得403 Forbidden对于我们的许多用户。



你能检查一下是怎么回事?我们的API控制台很干净,#calls是低声配额。

 由com.google.api.client.googleapis引发。 json.GoogleJsonResponseException:403 Forbidden 
{
code:403,
errors:[{
domain:global,
message :服务超限,
原因:serviceLimit
}],
消息:超出服务限额
}


,位于com.google.api.client.googleapis.json.GoogleJsonResponseException.from(GoogleJsonResponseException.java:145)〜[google-api-client-1.15.0-rc.jar:1.15.0-rc]
,位于com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest.newExceptionOnError(AbstractGoogleJsonClientRequest.java:111)〜[google-api-client-1.15.0-rc.jar:1.15.0-rc ]
在com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest.newExceptionOnError(AbstractGoogleJsonClientRequest.java:38)〜[google-api-client-1.15.0-rc.jar:1.15.0- rc]
com.google.api.clie nt.googleapis.services.AbstractGoogleClientRequest $ 1.interceptResponse(AbstractGoogleClientRequest.java:312)〜[google-api-client-1.15.0-rc.jar:1.15.0-rc]
,位于com.google.api。 client.tttt.HttpRequest.execute(HttpRequest.java:1042)〜[google-http-client-1.15.0-rc.jar:na]
,位于com.google.api.client.googleapis.services.AbstractGoogleClientRequest在com.google.api.client.googleapis.services.AbstractGoogleClientRequest上执行.executeUnparsed(AbstractGoogleClientRequest.java:410)〜[google-api-client-1.15.0-rc.jar:1.15.0-rc]
。通过com.google.api.client.googleapis.services.AbstractGoogleClientRequest.execute获取executeUnparsed(AbstractGoogleClientRequest.java:343)〜[google-api-client-1.15.0-rc.jar:1.15.0-rc]
(AbstractGoogleClientRequest.java:460)〜[google-api-client-1.15.0-rc.jar:1.15.0-rc]

$ b $如果此API与Google Directory API类似,这可能意味着您正在达到每用户的费率限制。例如。目录API默认为每个用户每秒15个请求,然后返回相同的403错误。要解决此问题,请在Google API控制台中更改配额,或每秒减少请求次数。请参阅:

API控制台: https:// code.google.com/apis/console/



关于配额的文档: https://developers.google.com/console/help/#cappingusage


Hello Google Tasks API team,

Since a couple of days ago we've started getting "403 Forbidden" for many of our users.

Can you please check what is going on? Our API console is clean, #calls are way bellow quotas.

Caused by: com.google.api.client.googleapis.json.GoogleJsonResponseException: 403 Forbidden
{
  "code" : 403,
  "errors" : [ {
    "domain" : "global",
    "message" : "Serving Limit Exceeded",
    "reason" : "serviceLimit"
  } ],
  "message" : "Serving Limit Exceeded"
}


at com.google.api.client.googleapis.json.GoogleJsonResponseException.from(GoogleJsonResponseException.java:145) ~[google-api-client-1.15.0-rc.jar:1.15.0-rc]
    at com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest.newExceptionOnError(AbstractGoogleJsonClientRequest.java:111) ~[google-api-client-1.15.0-rc.jar:1.15.0-rc]
    at com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest.newExceptionOnError(AbstractGoogleJsonClientRequest.java:38) ~[google-api-client-1.15.0-rc.jar:1.15.0-rc]
    at com.google.api.client.googleapis.services.AbstractGoogleClientRequest$1.interceptResponse(AbstractGoogleClientRequest.java:312) ~[google-api-client-1.15.0-rc.jar:1.15.0-rc]
    at com.google.api.client.http.HttpRequest.execute(HttpRequest.java:1042) ~[google-http-client-1.15.0-rc.jar:na]
    at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:410) ~[google-api-client-1.15.0-rc.jar:1.15.0-rc]
    at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:343) ~[google-api-client-1.15.0-rc.jar:1.15.0-rc]
    at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.execute(AbstractGoogleClientRequest.java:460) ~[google-api-client-1.15.0-rc.jar:1.15.0-rc]

解决方案

If this API is anything like the Google Directory API, this could mean you are hitting a "per user" rate limit. E.g. the directory API defaults to 15 requests per second per user, then returns this same 403 error. To fix this, change the quota in the Google API console, or make fewer requests per second. See:

API console: https://code.google.com/apis/console/

Documentation about quotas: https://developers.google.com/console/help/#cappingusage

这篇关于Google任务API:403禁止,超出服务限制的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆