Java environments (e.g. Java 6, Android 2.3, App Engine, or All)?
Java & Android for my case, but it would be appropriate for All.
Please describe the feature requested.
I would like to be able to cancel a request generated by
com.google.api.client.googleapis.services.AbstractGoogleClient.
This probably would require an executeAsync method parallel to
AbstractGoogleClientRequest.execute. An AbstractGoogleClient.cancelAll
method would work for my case (ie, cancel all pending requests generated by
that client), but that's not as clean an API.
--
You received this message because this project is configured to send all
issue notifications to this address.
You may adjust your notification preferences at:
https://code.google.com/hosting/settings
google-api-...@googlecode.com
unread,
Dec 30, 2014, 11:40:43 AM12/30/14
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
Canceling an HTTP request that has been sent on the wire is not a good
idea. The only way to do this is by closing the connection, but the server
may never know that the client has closed so it may continue doing what
it's doing. This wastes resources and introduces network latencies.
Adding such an interface requires changes at both ends, and is difficult to
implement based on HTTP. If you really want to cancel an ongoing request,
you could call HttpRequest.executeAsync(), get a Future, and abandon it
once it times out. But again, this may cause resource waste at the server
side.
google-api-...@googlecode.com
unread,
Dec 30, 2014, 1:08:09 PM12/30/14
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
There's an executeAsync() method implemented by the underlining HttpRequest
[1], you can get access to it by calling
AbstractGoogleClientRequest.buildHttpRequest() [2].
Although named as executeAsync(), it's not a true async interface. But it
should be sufficient for your case.