增加Google电子表格配额 [英] Increase Google Spreadsheet Quota

查看:112
本文介绍了增加Google电子表格配额的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

  1. 想要达到的目标
  1. ​What you are trying to achieve.

我们有很多电子表格,这些电子表格具有按时间触发器运行的脚本.每次运行都会使用时间触发配额,对于Google G套件,每天最多可设置6个小时.想象一下,我们有50个电子表格,每个电子表格都有一个每小时触发一次的脚本,该脚本需要3分钟才能运行.在这种情况下,它将使用50 * 24 * 3 = 3600分钟= 6小时,即所有给定的qouta.

We have a lot of spreadsheets that have scripts running by time triggers. Every run uses time trigger quota which has a cap of 6 hours a day for Google G suite. Imaging that we have 50 spreadsheets, each with an hourly trigger that runs a script that takes 3 minutes to run. In such a case, it will use 50*24*3 = 3600 minutes = 6 hours, i.e. all given qouta.

我们正在尝试使用所需的时间触发器来创建尽可能多的电子表格.

We are trying to be able to create as many spreadsheet with such time triggers as we need.

  1. 预期的行为.

  1. The expected behaviour.

所有电子表格触发器均可正常运行.

All spreadsheets triggers running without failures.

  • 实际行为

  • The actual behaviour

    我们在使用过多计算机时间一天的服务中遇到错误

    We are getting error Service using too much computer time for one day

  • 重现您的问题的步骤.

  • Steps to reproduce your issue. ​

    创建时间触发器,该触发器将每分钟以60秒的运行时间运行脚本,并在G Suite帐户下等待6个小时,或者创建100个这样的触发器,以免等待太久.在这种情况下,您会在36分钟内收到错误消息.

    Create time trigger that will run a script with 60 seconds runtime every minute and wait for 6 hours under G suite account, or create a 100 of such triggers in order not to wait so long. In such case you will get an error within 36 minutes.

  • 推荐答案

    Google Apps Scrpt-Google Services的配额页面是最近"的,更新.现在,它包括灵活的早期访问配额:

    The Google Apps Scrpt - Quotas for Google Services page was "recently" updated. It now includes Flexible quotas for Early Access:

    通常,如果脚本执行超出上述配额或限制之一,则脚本执行将停止并返回适当的错误消息.这可能会使脚本的数据处于不确定状态.

    Normally, if a script execution exceeds one of the above quotas or limitations, the script execution stops and an appropriate error message is returned. This can potentially leave the script's data in an indefinite state.

    在灵活配额系统下,此类硬配额限制已删除.脚本达到配额限制后不会停止.而是将它们延迟到配额可用之前,这时脚本将恢复执行.一旦开始使用配额,便会以固定的速度重新填充配额.为了合理使用,脚本延迟很少发生.

    Under the flexible quota system, such hard quota limits are removed. Scripts do not stop when they reach a quota limit. Rather, they are delayed until quota becomes available, at which point the script execution resumes. Once quotas begin being used, they are refilled at a regular rate. For reasonable usage, script delays are rare.

    一种替代方法是使用其他Google API,例如 Google云端硬盘REST API Google表格API 等.

    An alternative could be the use of other Google APIS like Google Drive REST API, Google Sheets API, etc.

    这篇关于增加Google电子表格配额的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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