[Action Required] Please migrate off JSON-RPC and Global HTTP Batch Endpoints

56 views
Skip to first unread message

Faustino Rodriguez

unread,
Mar 20, 2019, 9:59:21 AM3/20/19
to Google Apps Script Community
This is a message a few of use received last year (on March and October) apparently in relation with the use of DriveApp class in GAS
I haven't heard anything else about it, but it was announcing the change for coming March 25, 2019

- Is this something we still should be worry about?

Original message first paragraph:
"You are receiving this email because, either directly or indirectly, one or more of your Google Cloud Projects used either the JSON-RPC or Global HTTP Batch serving endpoint; both of which are scheduled to be turned down on March 25, 2019."

Eric Koleda

unread,
Mar 20, 2019, 10:27:03 AM3/20/19
to google-apps-sc...@googlegroups.com
Interesting, I use a lot of DriveApp but never got that email. Are you sure you didn't use the Drive API's batch endpoint directly in any of your code?

- Eric

--
You received this message because you are subscribed to the Google Groups "Google Apps Script Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-script-c...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-apps-script-community.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-script-community/7e243984-9f3f-418c-9304-bfd13476aaa8%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Faustino Rodriguez

unread,
Mar 20, 2019, 11:11:28 AM3/20/19
to Google Apps Script Community
sure I am
i don't even know what is that batch endpoint

the project that was referred in that communication is using DriveApp ,but not the advanced Drive Api service


On Wednesday, March 20, 2019 at 10:27:03 AM UTC-4, Eric Koleda wrote:
Interesting, I use a lot of DriveApp but never got that email. Are you sure you didn't use the Drive API's batch endpoint directly in any of your code?

- Eric

On Wed, Mar 20, 2019 at 9:59 AM Faustino Rodriguez <fau...@thexs.ca> wrote:
This is a message a few of use received last year (on March and October) apparently in relation with the use of DriveApp class in GAS
I haven't heard anything else about it, but it was announcing the change for coming March 25, 2019

- Is this something we still should be worry about?

Original message first paragraph:
"You are receiving this email because, either directly or indirectly, one or more of your Google Cloud Projects used either the JSON-RPC or Global HTTP Batch serving endpoint; both of which are scheduled to be turned down on March 25, 2019."

--
You received this message because you are subscribed to the Google Groups "Google Apps Script Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-script-community+unsub...@googlegroups.com.

Riël Notermans

unread,
Mar 20, 2019, 11:16:50 AM3/20/19
to Google Apps Script Community
The email specifically mentioned one project ID (I dont have this project anymore) but also this API:

drive@v2beta

Is that Drive advanced OR DriveApp?

Op wo 20 mrt. 2019 16:11 schreef Faustino Rodriguez <fau...@thexs.ca>:
sure I am
i don't even know what is that batch endpoint

the project that was referred in that communication is using DriveApp ,but not the advanced Drive Api service

On Wednesday, March 20, 2019 at 10:27:03 AM UTC-4, Eric Koleda wrote:
Interesting, I use a lot of DriveApp but never got that email. Are you sure you didn't use the Drive API's batch endpoint directly in any of your code?

- Eric

On Wed, Mar 20, 2019 at 9:59 AM Faustino Rodriguez <fau...@thexs.ca> wrote:
This is a message a few of use received last year (on March and October) apparently in relation with the use of DriveApp class in GAS
I haven't heard anything else about it, but it was announcing the change for coming March 25, 2019

- Is this something we still should be worry about?

Original message first paragraph:
"You are receiving this email because, either directly or indirectly, one or more of your Google Cloud Projects used either the JSON-RPC or Global HTTP Batch serving endpoint; both of which are scheduled to be turned down on March 25, 2019."

--
You received this message because you are subscribed to the Google Groups "Google Apps Script Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-script-c...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Google Apps Script Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-script-c...@googlegroups.com.

Faustino Rodriguez

unread,
Mar 20, 2019, 11:46:09 AM3/20/19
to Google Apps Script Community
similar in my case, as follow:

Your projects listed below will be affected by this change:

Project IDAPI NameAPI VersionJSON-RPC or Global HTTP Batch Endpoint?
api-project-1234567890Google Drive APIdrive@v2betaGlobal HTTP Batch Endpoint



On Wednesday, March 20, 2019 at 11:16:50 AM UTC-4, Riël Notermans wrote:
The email specifically mentioned one project ID (I dont have this project anymore) but also this API:

drive@v2beta

Is that Drive advanced OR DriveApp?

Op wo 20 mrt. 2019 16:11 schreef Faustino Rodriguez <fau...@thexs.ca>:
sure I am
i don't even know what is that batch endpoint

the project that was referred in that communication is using DriveApp ,but not the advanced Drive Api service

On Wednesday, March 20, 2019 at 10:27:03 AM UTC-4, Eric Koleda wrote:
Interesting, I use a lot of DriveApp but never got that email. Are you sure you didn't use the Drive API's batch endpoint directly in any of your code?

- Eric

On Wed, Mar 20, 2019 at 9:59 AM Faustino Rodriguez <fau...@thexs.ca> wrote:
This is a message a few of use received last year (on March and October) apparently in relation with the use of DriveApp class in GAS
I haven't heard anything else about it, but it was announcing the change for coming March 25, 2019

- Is this something we still should be worry about?

Original message first paragraph:
"You are receiving this email because, either directly or indirectly, one or more of your Google Cloud Projects used either the JSON-RPC or Global HTTP Batch serving endpoint; both of which are scheduled to be turned down on March 25, 2019."

--
You received this message because you are subscribed to the Google Groups "Google Apps Script Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-script-community+unsub...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Google Apps Script Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-script-community+unsub...@googlegroups.com.

Eric Koleda

unread,
Mar 20, 2019, 11:47:07 AM3/20/19
to google-apps-sc...@googlegroups.com
I see. v2beta is a beta version of the v2 API, and generally not available externally. Was the script in question quite old? It could be that when DriveApp was new it was using this version of the API under the covers.

- Eric

To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-script-c...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Google Apps Script Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-script-c...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Google Apps Script Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-script-c...@googlegroups.com.

Faustino Rodriguez

unread,
Mar 20, 2019, 11:52:30 AM3/20/19
to Google Apps Script Community
the script (a Google Sheets add-on) was created on March 2014
- but it has been often updated since then
- and the message I got with that warning is from last Oct 18, 2018
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-script-community+unsub...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Google Apps Script Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-script-community+unsub...@googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Google Apps Script Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-script-community+unsub...@googlegroups.com.

Romain Vialard

unread,
Mar 20, 2019, 12:58:08 PM3/20/19
to Google Apps Script Community
I also received that email, it listed only one project and indeed that project was using a batch endpoint. Not on server side / Apps Script but on client side : I was using the Drive SDK V3 on client side and was calling the batch endpoint to get info on several files in one call (by proving a list of IDs).

Are you making Drive calls on client side? 

Romain Vialard

unread,
Mar 20, 2019, 1:15:25 PM3/20/19
to Google Apps Script Community
Also, not directly related, but here's a code sample comparing the performance of methods to get data from the Drive API: 

Specifically, to list permissions of different files, you need to make one call per file. 
In Apps Script you usually have to make a loop and get the permission for each file one by one. To speed the process, a solution could be to use the rather new fetchall method, letting you make several requests to the Drive API in parallel. But in fact that's not really scalable (you will quickly get "Rate Limit Exceeded" errors from the API). That's when the batch endpoint comes to the rescue, letting you safely send a batch of requests to the API.

To get permissions for 1000 files, it usually takes more than 220s with a standard loop and only 14s when using the batch endpoint (I wasn't able to get permissions for 1000 files with fetchall, too many errors but retrieving permissions of 500 files took 23s).

Faustino Rodriguez

unread,
Mar 20, 2019, 1:46:30 PM3/20/19
to Google Apps Script Community
No, I am not making Drive calls client side

Just in case I searched for 
googleapis.com/drive

And there is nothing like that in my code

Adam Morris

unread,
Mar 20, 2019, 8:30:21 PM3/20/19
to google-apps-sc...@googlegroups.com
When I use the fetchall method, I divide the calls into chunks. Also, the fetchall method can be used with any API endpoint. I have found it to be an extremely useful method and many of my projects are using it in production. The batch endpoint is obviously better but it's limited to only the drive api.

————————————————————————————

Adam Morris | IT Systems & English Teacher | IGB International School
Jalan Sierramas Utama, Sierramas,
47000 Sungai Buloh, Selangor DE, Malaysia

t    +60 3 6145 4688
f    +60 3 6145 4600
w   www.igbis.edu.my
e    adam....@igbis.edu.my

————————————————————————————


--
You received this message because you are subscribed to the Google Groups "Google Apps Script Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-script-c...@googlegroups.com.

Romain Vialard

unread,
Mar 21, 2019, 1:59:41 AM3/21/19
to Google Apps Script Community

Adam Morris

unread,
Mar 21, 2019, 2:34:01 AM3/21/19
to google-apps-sc...@googlegroups.com
I didn't realize there are so many of them available! When did that happen?

--
You received this message because you are subscribed to the Google Groups "Google Apps Script Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-script-c...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-apps-script-community.

Dimu Designs

unread,
Mar 21, 2019, 2:26:01 PM3/21/19
to google-apps-sc...@googlegroups.com
Batch endpoints have been around for a while. Check the JSON-formatted discovery doc for the corresponding API and you're bound to find a "batch" property somewhere.

Here's a link to the default JSON-formatted discovery doc listing for most google apis. Each item has a property called 'discovertyRestUrl' with a link to the full JSON schema for a given API. That schema typical has a 'batchPath' property.


On Thursday, March 21, 2019 at 2:34:01 AM UTC-4, Adam Morris wrote:
I didn't realize there are so many of them available! When did that happen?

On Thu, Mar 21, 2019 at 1:59 PM Romain Vialard <romain....@gmail.com> wrote:

--
You received this message because you are subscribed to the Google Groups "Google Apps Script Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-script-community+unsub...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages