artiya4u / google-http-java-client

Automatically exported from code.google.com/p/google-http-java-client
0 stars 0 forks source link

User-agent repeatedly added on retry #119

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Version of google-http-java-client (e.g. 1.5.0-beta)?
1.10.0-beta-SNAPSHOT

Java environment (e.g. Java 6, Android 2.3, App Engine)?
Java 6

Describe the problem.
If the httpRequest fails with a retryable error, then the User-Agent string 
will again be appended to the User-Agent, resulting in duplication. After 10 
retries, you'll have a very long User-Agent string.
http://code.google.com/p/google-http-java-client/source/browse/google-http-clien
t/src/main/java/com/google/api/client/http/HttpRequest.java?name=1.9.0-beta#788

How would you expect it to be fixed?
Mark that you've set the user-agent once, and then don't set it again on 
retries.

Original issue reported on code.google.com by nherr...@google.com on 22 May 2012 at 4:23

GoogleCodeExporter commented 9 years ago
Thank you for reporting this issue Nathan!

Original comment by rmis...@google.com on 22 May 2012 at 12:29

GoogleCodeExporter commented 9 years ago
http://codereview.appspot.com/6215076/

Original comment by rmis...@google.com on 22 May 2012 at 2:13

GoogleCodeExporter commented 9 years ago
Nathan, this will be available to use when I do the next sync into the internal 
codebase (probably tomorrow).

Original comment by rmis...@google.com on 23 May 2012 at 12:55