ios - 解析错误代码 : 155 - Exceeded request limit

标签 ios parse-platform

我使用的是每秒 30 个请求限制的免费计划。我的问题是如果一秒内超过 30 个会怎样?超过 30 的请求是否会被推送到下一秒?如果是这种情况,是否有一种方法可以优先处理延迟的请求以确保它们在下一秒通过?

如果他们没有被推送到下一秒的请求,我将如何在不升级我的帐户的情况下克服这个问题?我在想,如果我收到错误 155 代码,我可以记忆起用于检索数据的方法,并继续这样做,直到成功。

最佳答案

TL:DR

They will be dropped.

长答案: 来自解析常见问题解答:

What happens if my app exceeds the requests/second limit?

Once your app exceeds the request limit, any further requests will be dropped until the average number of requests sent over a trailing 60 second window drops under the request limit for this app. Please refer to the preceeding question for more information on how this limit is calculated. When a request is dropped due to exceeding the request limit, the API will respond with a 155 error code (Request Limit Exceeded). To prevent the requests from failing you should adjust the request limit slider for the relevant app on the Account Overview page. Please note that you can see your actual requests/second on the Performance Analytics tab.

来源:Parse FAQ

那么,在不升级计划的情况下达到(免费)限制后,您可以做什么? 好吧,首先去看看你的分析仪表盘上的分析图。仔细观察,想想你是否需要那么多请求。 完成后,请执行 performance-optimization。在此处查看解析文档以了解如何执行此操作(针对您的特定平台):

Parse documentation

以 IOS 大师赛的性能指南为例:

Performance Guide for iOS

如果您检查了所有内容并且确定您的代码没有任何优化(例如缓存数据、将请求限制为 1/分钟等...),您很可能必须升级您的计划。

但是,您可以做什么来捕获您的请求错误?

正如您自己所说,您可以不断尝试请求信息,直到收到肯定的请求。问题是所有这些尝试都会加到您的 req/m 计数器中,因此超出了您的有限停留时间。

最佳选择:不要达到限制。

解决选项:尝试另一个请求。也许三分之一。然后停下来等待一分钟左右,但提供一些信息,例如 Server currently not available。请稍后再试。 然后,再次检查您的代码优化。

错误的选择:不断尝试请求直到你得到它。

关于ios - 解析错误代码 : 155 - Exceeded request limit,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/34520133/

相关文章:

java - Facebook/Parse 登录行为异常 : The proxied app is not already installed

unity-game-engine - Unity3d Parse FindAsync 方法卡住 UI

ios - Phonegap和MobileIron兼容性

ios - AVA录音机!我需要从 0 到 120 的幅度范围内获得分贝值 ios swift?

ios - 无法使用 NSJSONSerialization 解析 JSON

ios - XCode 4 "add build setting condition"未启用

jquery - 获取ImageUri的文件内容

ios - 为 iOS 构建 block 功能的方向

ios - SWIFT:修改某些解析列/对于某些用户而言出现问题。 != 访问控制列表

iphone - 应用程序仅在iPhone设备上崩溃而不在模拟器中崩溃