stephaniewang526 commented on a change in pull request #13896:
URL: https://github.com/apache/beam/pull/13896#discussion_r588465942
##########
File path:
sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/bigquery/BigQueryServicesImpl.java
##########
@@ -1175,18 +1174,31 @@ private StorageClientImpl(BigQueryOptions options)
throws IOException {
.build());
UnaryCallSettings.Builder<CreateReadSessionRequest, ReadSession>
createReadSessionSettings =
- builder.getStubSettingsBuilder().createReadSessionSettings();
+ settingsBuilder.getStubSettingsBuilder().createReadSessionSettings();
- RetrySettings.Builder retrySettings =
+ createReadSessionSettings.setRetrySettings(
createReadSessionSettings
.getRetrySettings()
.toBuilder()
.setInitialRpcTimeout(org.threeten.bp.Duration.ofHours(2))
.setMaxRpcTimeout(org.threeten.bp.Duration.ofHours(2))
- .setTotalTimeout(org.threeten.bp.Duration.ofHours(2));
+ .setTotalTimeout(org.threeten.bp.Duration.ofHours(2))
+ .build());
- createReadSessionSettings.setRetrySettings(retrySettings.build());
- this.client = BigQueryReadClient.create(builder.build());
+ UnaryCallSettings.Builder<SplitReadStreamRequest,
SplitReadStreamResponse>
+ splitReadStreamSettings =
+
settingsBuilder.getStubSettingsBuilder().splitReadStreamSettings();
+
+ splitReadStreamSettings.setRetrySettings(
+ splitReadStreamSettings
+ .getRetrySettings()
+ .toBuilder()
+ .setInitialRpcTimeout(org.threeten.bp.Duration.ofSeconds(30))
+ .setMaxRpcTimeout(org.threeten.bp.Duration.ofSeconds(30))
+ .setTotalTimeout(org.threeten.bp.Duration.ofSeconds(30))
+ .build());
Review comment:
This is good -- shouldn't need to call `.build()` again on
`splitReadStreamSettings`.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]