Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(5600)

Issue 5539055: Adding Batch support for Google APIs (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
12 years, 3 months ago by rmistry
Modified:
11 years, 11 months ago
Reviewers:
aalbert, yanivi
Base URL:
https://google-api-java-client.googlecode.com/hg/
Visibility:
Public.

Patch Set 1 #

Patch Set 2 : Minor fixes #

Patch Set 3 : Removing JsonHttpParser.parserForContent #

Patch Set 4 : Minor fixes #

Patch Set 5 : Adding unit tests and some improvements to BatchRequest. #

Patch Set 6 : Minor fixes #

Total comments: 22

Patch Set 7 : Addressing code review comments #

Patch Set 8 : Minor fixes #

Patch Set 9 : Syncing with head #

Patch Set 10 : Adding @since 1.9 #

Total comments: 2

Patch Set 11 : Adding batch() in GoogleClient and removing deprecated calls from BatchRequestTest #

Patch Set 12 : Addressing review comments #

Patch Set 13 : Minor fix #

Patch Set 14 : Minor fix #

Patch Set 15 : Adding javadoc for unauthenticated requests #

Patch Set 16 : Minor fix #

Total comments: 50

Patch Set 17 : Addressing code review comments #

Patch Set 18 : Adding unit test #

Total comments: 2

Patch Set 19 : Addressing code review comments #

Patch Set 20 : Minor fix #

Patch Set 21 : Proposal to solve the unauthentication problem #

Patch Set 22 : Minor fix #

Patch Set 23 : Handling changes in http://codereview.appspot.com/6121048/ #

Patch Set 24 : Adding MultipartMixedContent #

Total comments: 10

Patch Set 25 : Testing #

Patch Set 26 : Addressing code review comments #

Patch Set 27 : Minor fixes #

Patch Set 28 : Removing 'json' from package and class names #

Total comments: 4

Patch Set 29 : Using changes in http://codereview.appspot.com/6174052/ #

Total comments: 83

Patch Set 30 : Addressing code review comments #

Patch Set 31 : Minor fix #

Patch Set 32 : Minor fix #

Patch Set 33 : Minor fix #

Patch Set 34 : Minor fix #

Patch Set 35 : Minor fix #

Total comments: 44

Patch Set 36 : Addressing review comments #

Patch Set 37 : Fixing Javadoc #

Patch Set 38 : Minor fixes #

Patch Set 39 : Adding Headers to FakeLowLevelHttpResponse #

Patch Set 40 : Minor fix #

Total comments: 26

Patch Set 41 : Addressing code review comments #

Patch Set 42 : Minor fix #

Patch Set 43 : Adding unit tests for 401s #

Patch Set 44 : Minor fix #

Total comments: 8

Patch Set 45 : Addressing code review comments #

Patch Set 46 : Minor fix #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1428 lines, -0 lines) Patch
A google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 1 chunk +65 lines, -0 lines 0 comments Download
A google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 1 chunk +250 lines, -0 lines 0 comments Download
A google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchUnparsedResponse.java View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 1 chunk +320 lines, -0 lines 0 comments Download
A google-api-client/src/main/java/com/google/api/client/googleapis/batch/MultipartMixedContent.java View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 1 chunk +133 lines, -0 lines 0 comments Download
A google-api-client/src/main/java/com/google/api/client/googleapis/batch/package-info.java View 1 2 3 4 5 6 7 8 9 19 20 21 22 23 24 25 26 27 1 chunk +27 lines, -0 lines 0 comments Download
A google-api-client/src/main/java/com/google/api/client/googleapis/json/GoogleJsonErrorContainer.java View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 1 chunk +40 lines, -0 lines 0 comments Download
M google-api-client/src/main/java/com/google/api/client/googleapis/services/GoogleClient.java View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 3 chunks +50 lines, -0 lines 0 comments Download
A google-api-client/src/test/java/com/google/api/client/googleapis/batch/BatchRequestTest.java View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 1 chunk +416 lines, -0 lines 0 comments Download
A google-api-client/src/test/java/com/google/api/client/googleapis/batch/MultipartMixedContentTest.java View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 1 chunk +85 lines, -0 lines 0 comments Download
A google-api-client/src/test/java/com/google/api/client/googleapis/json/GoogleJsonErrorContainerTest.java View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 1 chunk +42 lines, -0 lines 0 comments Download

Messages

Total messages: 42
rmistry
12 years, 3 months ago (2012-01-13 16:46:33 UTC) #1
rmistry
Updated CL to include unit tests. Also, updated CL to pass in transport and httpRequestInitializer ...
12 years, 3 months ago (2012-01-20 23:28:33 UTC) #2
yanivi
First round of review comments. Lots of design questions. http://codereview.appspot.com/5539055/diff/10001/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java File google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java (right): http://codereview.appspot.com/5539055/diff/10001/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java#newcode47 google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java:47: ...
12 years, 3 months ago (2012-01-27 18:39:42 UTC) #3
yanivi
http://codereview.appspot.com/5539055/diff/10001/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java File google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java (right): http://codereview.appspot.com/5539055/diff/10001/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java#newcode45 google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java:45: public interface BatchCallback<T> { I think we should also ...
12 years, 3 months ago (2012-01-27 18:54:48 UTC) #4
rmistry
http://codereview.appspot.com/5539055/diff/10001/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java File google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java (right): http://codereview.appspot.com/5539055/diff/10001/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java#newcode45 google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java:45: public interface BatchCallback<T> { On 2012/01/27 18:54:49, yanivi wrote: ...
12 years, 3 months ago (2012-01-31 23:17:54 UTC) #5
rmistry
Ping.
12 years, 1 month ago (2012-03-13 13:52:01 UTC) #6
rmistry
Synced with head.
12 years, 1 month ago (2012-03-26 19:21:13 UTC) #7
yanivi
Sorry I haven't had time to look at it yet. I think we need to ...
12 years, 1 month ago (2012-03-27 14:07:47 UTC) #8
rmistry
Added @since 1.9
12 years ago (2012-04-05 13:55:25 UTC) #9
aalbert
It seems redundant to have to construct a BatchRequest with an HttpTransport, HttpRequestInitializer & JsonFactory ...
12 years ago (2012-04-10 20:16:54 UTC) #10
aalbert
http://codereview.appspot.com/5539055/diff/32001/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java File google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java (right): http://codereview.appspot.com/5539055/diff/32001/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java#newcode300 google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java:300: multipartBody.append(data); This is wrong. data.toString() returns something like: "com.google.api.client.http.json.JsonHttpContent@1b273cc" ...
12 years ago (2012-04-10 22:33:20 UTC) #11
aalbert
BatchRequest.execute* methods do not handle Auth Token expiration. It seems that the batch request succeeds ...
12 years ago (2012-04-10 22:42:12 UTC) #12
rmistry
On 2012/04/10 20:16:54, aalbert wrote: > It seems redundant to have to construct a BatchRequest ...
12 years ago (2012-04-16 14:44:19 UTC) #13
rmistry
http://codereview.appspot.com/5539055/diff/32001/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java File google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java (right): http://codereview.appspot.com/5539055/diff/32001/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java#newcode300 google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java:300: multipartBody.append(data); On 2012/04/10 22:33:20, aalbert wrote: > This is ...
12 years ago (2012-04-16 15:28:04 UTC) #14
rmistry
On 2012/04/10 22:42:12, aalbert wrote: > BatchRequest.execute* methods do not handle Auth Token expiration. > ...
12 years ago (2012-04-16 19:09:50 UTC) #15
aalbert
Can you expand a bit on why this is hard? On 2012/04/16 19:09:50, rmistry wrote: ...
12 years ago (2012-04-16 19:46:40 UTC) #16
rmistry
On 2012/04/16 19:46:40, aalbert wrote: > Can you expand a bit on why this is ...
12 years ago (2012-04-16 20:13:40 UTC) #17
aalbert
Can't the server side side check check the batched requests before executing them and see ...
12 years ago (2012-04-16 20:49:05 UTC) #18
yanivi
Sorry I haven't had time to review this deeply yet, but I've gotten a chance ...
12 years ago (2012-04-20 21:12:34 UTC) #19
yanivi
More comments... http://codereview.appspot.com/5539055/diff/51002/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java File google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java (right): http://codereview.appspot.com/5539055/diff/51002/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java#newcode66 google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java:66: public void onFailure(GoogleJsonError e, GoogleHeaders responseHeaders) { ...
12 years ago (2012-04-20 22:17:27 UTC) #20
aalbert
http://codereview.appspot.com/5539055/diff/51002/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java File google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java (right): http://codereview.appspot.com/5539055/diff/51002/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java#newcode95 google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java:95: * Note: If an access token expires then the ...
12 years ago (2012-04-20 22:24:11 UTC) #21
rmistry
Addressed all comments except the last two in BatchRequest, I will work on them next. ...
12 years ago (2012-04-24 13:51:08 UTC) #22
yanivi
Just a few quick comments, but still not a thorough review... http://codereview.appspot.com/5539055/diff/51002/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java File google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java (right): ...
12 years ago (2012-04-24 20:47:43 UTC) #23
rmistry
http://codereview.appspot.com/5539055/diff/51002/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java File google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java (right): http://codereview.appspot.com/5539055/diff/51002/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java#newcode66 google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java:66: public void onFailure(GoogleJsonError e, GoogleHeaders responseHeaders) { On 2012/04/24 ...
12 years ago (2012-04-25 12:50:17 UTC) #24
rmistry
I implemented a proposal to solve the unauthenticated requests problem. If the design looks ok, ...
12 years ago (2012-04-26 12:14:10 UTC) #25
rmistry
Brought in MultipartMixedContent based on our IM conversation
12 years ago (2012-04-30 17:08:10 UTC) #26
yanivi
At this point, I'm still reviewing it at a high level. Some really interesting comments ...
12 years ago (2012-04-30 20:10:39 UTC) #27
rmistry
http://codereview.appspot.com/5539055/diff/78001/google-api-client/src/main/java/com/google/api/client/googleapis/batch/json/BatchJsonRequest.java File google-api-client/src/main/java/com/google/api/client/googleapis/batch/json/BatchJsonRequest.java (right): http://codereview.appspot.com/5539055/diff/78001/google-api-client/src/main/java/com/google/api/client/googleapis/batch/json/BatchJsonRequest.java#newcode157 google-api-client/src/main/java/com/google/api/client/googleapis/batch/json/BatchJsonRequest.java:157: * @param credential The credential to use when creating ...
12 years ago (2012-05-03 12:17:08 UTC) #28
yanivi
Next round of comments, this time starting to get into some of the details... http://codereview.appspot.com/5539055/diff/96003/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java ...
12 years ago (2012-05-04 18:58:38 UTC) #29
yanivi
More comments... http://codereview.appspot.com/5539055/diff/96003/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java File google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java (right): http://codereview.appspot.com/5539055/diff/96003/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java#newcode48 google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java:48: public interface BatchCallback<T, E> { [optional] BatchCallback ...
12 years ago (2012-05-04 20:47:35 UTC) #30
rmistry
http://codereview.appspot.com/5539055/diff/96003/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java File google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java (right): http://codereview.appspot.com/5539055/diff/96003/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java#newcode29 google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchCallback.java:29: batch.queue(volumesList, credential, Volumes.class, GoogleJsonError.class, On 2012/05/04 18:58:38, yanivi wrote: ...
11 years, 12 months ago (2012-05-07 19:37:36 UTC) #31
yanivi
next batch of comments... http://codereview.appspot.com/5539055/diff/96003/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java File google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java (right): http://codereview.appspot.com/5539055/diff/96003/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java#newcode113 google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java:113: private boolean retryUnsuccessfulRequests = true; ...
11 years, 12 months ago (2012-05-09 16:27:54 UTC) #32
yanivi
http://codereview.appspot.com/5539055/diff/111009/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java File google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java (right): http://codereview.appspot.com/5539055/diff/111009/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java#newcode184 google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java:184: HttpParser httpParser, httpParser and unsuccessfulResponseHandler shouldn't be parameters to ...
11 years, 12 months ago (2012-05-09 20:29:45 UTC) #33
yanivi
http://codereview.appspot.com/5539055/diff/111009/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java File google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java (right): http://codereview.appspot.com/5539055/diff/111009/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java#newcode176 google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java:176: * {@code null} is specified here then if the ...
11 years, 12 months ago (2012-05-09 21:05:03 UTC) #34
rmistry
Addressed all comments except one (HttpHeaders) http://codereview.appspot.com/5539055/diff/96002/google-api-client/src/test/java/com/google/api/client/googleapis/batch/BatchRequestTest.java File google-api-client/src/test/java/com/google/api/client/googleapis/batch/BatchRequestTest.java (right): http://codereview.appspot.com/5539055/diff/96002/google-api-client/src/test/java/com/google/api/client/googleapis/batch/BatchRequestTest.java#newcode248 google-api-client/src/test/java/com/google/api/client/googleapis/batch/BatchRequestTest.java:248: // public void ...
11 years, 11 months ago (2012-05-10 12:12:40 UTC) #35
rmistry
http://codereview.appspot.com/5539055/diff/96003/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchUnparsedResponse.java File google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchUnparsedResponse.java (right): http://codereview.appspot.com/5539055/diff/96003/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchUnparsedResponse.java#newcode132 google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchUnparsedResponse.java:132: responseHeaders.set(headerParts[0], headerParts[1]); On 2012/05/10 12:12:40, rmistry wrote: > On ...
11 years, 11 months ago (2012-05-10 13:24:44 UTC) #36
yanivi
almost there... http://codereview.appspot.com/5539055/diff/96002/google-api-client/src/test/java/com/google/api/client/googleapis/batch/BatchRequestTest.java File google-api-client/src/test/java/com/google/api/client/googleapis/batch/BatchRequestTest.java (right): http://codereview.appspot.com/5539055/diff/96002/google-api-client/src/test/java/com/google/api/client/googleapis/batch/BatchRequestTest.java#newcode248 google-api-client/src/test/java/com/google/api/client/googleapis/batch/BatchRequestTest.java:248: // public void testExecuteWithError() throws Exception { ...
11 years, 11 months ago (2012-05-10 21:13:29 UTC) #37
rmistry
http://codereview.appspot.com/5539055/diff/96002/google-api-client/src/test/java/com/google/api/client/googleapis/batch/BatchRequestTest.java File google-api-client/src/test/java/com/google/api/client/googleapis/batch/BatchRequestTest.java (right): http://codereview.appspot.com/5539055/diff/96002/google-api-client/src/test/java/com/google/api/client/googleapis/batch/BatchRequestTest.java#newcode248 google-api-client/src/test/java/com/google/api/client/googleapis/batch/BatchRequestTest.java:248: // public void testExecuteWithError() throws Exception { On 2012/05/10 ...
11 years, 11 months ago (2012-05-11 12:57:57 UTC) #38
rmistry
Added unit tests for 401s and Void callbacks.
11 years, 11 months ago (2012-05-11 14:35:29 UTC) #39
yanivi
http://codereview.appspot.com/5539055/diff/113025/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java File google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java (right): http://codereview.appspot.com/5539055/diff/113025/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java#newcode222 google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java:222: public HttpResponse executeUnparsed() throws IOException { package private? http://codereview.appspot.com/5539055/diff/113025/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchUnparsedResponse.java ...
11 years, 11 months ago (2012-05-11 15:37:27 UTC) #40
rmistry
http://codereview.appspot.com/5539055/diff/113025/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java File google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java (right): http://codereview.appspot.com/5539055/diff/113025/google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java#newcode222 google-api-client/src/main/java/com/google/api/client/googleapis/batch/BatchRequest.java:222: public HttpResponse executeUnparsed() throws IOException { On 2012/05/11 15:37:27, ...
11 years, 11 months ago (2012-05-11 16:33:17 UTC) #41
yanivi
11 years, 11 months ago (2012-05-11 17:43:04 UTC) #42
LGTM
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b