https://codereview.appspot.com/6906051/diff/2001/apiclient/discovery.py File apiclient/discovery.py (right): https://codereview.appspot.com/6906051/diff/2001/apiclient/discovery.py#newcode63 apiclient/discovery.py:63: httplib2.RETRIES = 1 Not saying it is wrong, but ...
11 years, 9 months ago
(2012-12-07 19:02:56 UTC)
#2
11 years, 9 months ago
(2012-12-07 19:09:56 UTC)
#4
On 2012/12/07 19:07:53, jcgregorio_google wrote:
> https://codereview.appspot.com/6906051/diff/2001/apiclient/discovery.py
> File apiclient/discovery.py (right):
>
>
https://codereview.appspot.com/6906051/diff/2001/apiclient/discovery.py#newco...
> apiclient/discovery.py:63: httplib2.RETRIES = 1
> On 2012/12/07 19:02:56, Ali Afshar wrote:
> > Not saying it is wrong, but why did you decide on 1?
>
> It's the safest option, particularly for APIs where requests may be tied to
> money, for example, a request to kick off an expensive set of work in
BigQuery.
Ok, understood, but hopefully a failed request doesn't cost the user money in
that case.
LGTM, any documentation on how to change the value?
On 2012/12/07 19:09:56, Ali Afshar wrote: > On 2012/12/07 19:07:53, jcgregorio_google wrote: > > https://codereview.appspot.com/6906051/diff/2001/apiclient/discovery.py ...
11 years, 9 months ago
(2012-12-07 19:18:51 UTC)
#5
On 2012/12/07 19:09:56, Ali Afshar wrote:
> On 2012/12/07 19:07:53, jcgregorio_google wrote:
> > https://codereview.appspot.com/6906051/diff/2001/apiclient/discovery.py
> > File apiclient/discovery.py (right):
> >
> >
>
https://codereview.appspot.com/6906051/diff/2001/apiclient/discovery.py#newco...
> > apiclient/discovery.py:63: httplib2.RETRIES = 1
> > On 2012/12/07 19:02:56, Ali Afshar wrote:
> > > Not saying it is wrong, but why did you decide on 1?
> >
> > It's the safest option, particularly for APIs where requests may be tied to
> > money, for example, a request to kick off an expensive set of work in
> BigQuery.
>
> Ok, understood, but hopefully a failed request doesn't cost the user money in
> that case.
>
> LGTM, any documentation on how to change the value?
No docs changes, I think this actually fixes a bug in that
people probably presume that the underlying request is
only tried once. If someone wanted multiple retries it should
probably be done at a higher level with exponential back-off.
Committed in
http://code.google.com/p/google-api-python-client/source/detail?r=ab28805189b...
Issue 6906051: Set httplib2.RETRIES to 1.
(Closed)
Created 11 years, 9 months ago by jcgregorio_google
Modified 11 years, 9 months ago
Reviewers: Ali Afshar
Base URL:
Comments: 2