File tree Expand file tree Collapse file tree 2 files changed +8
-5
lines changed
main/java/com/google/cloud/spanner
test/java/com/google/cloud/spanner Expand file tree Collapse file tree 2 files changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -250,9 +250,11 @@ private List<Partition> partitionReadUsingIndex(
250250 }
251251 builder .setPartitionOptions (pbuilder .build ());
252252
253+ XGoogSpannerRequestId reqId =
254+ session .getRequestIdCreator ().nextRequestId (1 /*TODO: retrieve channelId*/ , 1 );
253255 final PartitionReadRequest request = builder .build ();
254256 try {
255- PartitionResponse response = rpc .partitionRead (request , options );
257+ PartitionResponse response = rpc .partitionRead (request , reqId . withOptions ( options ) );
256258 ImmutableList .Builder <Partition > partitions = ImmutableList .builder ();
257259 for (com .google .spanner .v1 .Partition p : response .getPartitionsList ()) {
258260 Partition partition =
@@ -313,9 +315,11 @@ private List<Partition> partitionQuery(
313315 }
314316 builder .setPartitionOptions (pbuilder .build ());
315317
318+ XGoogSpannerRequestId reqId =
319+ session .getRequestIdCreator ().nextRequestId (1 /*TODO: retrieve channelId*/ , 1 );
316320 final PartitionQueryRequest request = builder .build ();
317321 try {
318- PartitionResponse response = rpc .partitionQuery (request , options );
322+ PartitionResponse response = rpc .partitionQuery (request , reqId . withOptions ( options ) );
319323 ImmutableList .Builder <Partition > partitions = ImmutableList .builder ();
320324 for (com .google .spanner .v1 .Partition p : response .getPartitionsList ()) {
321325 Partition partition =
Original file line number Diff line number Diff line change @@ -239,9 +239,8 @@ public static void startStaticServer() throws IOException {
239239 "google.spanner.v1.Spanner/ExecuteStreamingSql" ,
240240 "google.spanner.v1.Spanner/GetSession" ,
241241 "google.spanner.v1.Spanner/ListSessions" ,
242- // TODO: Uncomment the methods when the implementation is completed.
243- // "google.spanner.v1.Spanner/PartitionQuery",
244- // "google.spanner.v1.Spanner/PartitionRead",
242+ "google.spanner.v1.Spanner/PartitionQuery" ,
243+ "google.spanner.v1.Spanner/PartitionRead" ,
245244 "google.spanner.v1.Spanner/Read" ,
246245 "google.spanner.v1.Spanner/Rollback" ,
247246 "google.spanner.v1.Spanner/StreamingRead" ));
You can’t perform that action at this time.
0 commit comments