paragpratim commented on code in PR #41329:
URL: https://github.com/apache/beam/pull/41329#discussion_r4572508011
##########
sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/bigquery/UpdateSchemaDestination.java:
##########
@@ -318,8 +344,16 @@ public void finishBundle(FinishBundleContext context)
throws Exception {
jobRef,
jobId.getRetryIndex());
try {
- jobService.startLoadJob(
- jobRef, loadConfig, new ByteArrayContent("text/plain", new
byte[0]));
+ ByteArrayContent content = new ByteArrayContent("text/plain",
new byte[0]);
+ if (loadJobReservation == null) {
+ jobService.startLoadJob(jobRef, loadConfig, content);
+ } else {
+ String reservation = loadJobReservation.get();
+ if (Strings.isNullOrEmpty(reservation)) {
Review Comment:
Thanks for pointing this out. I updated the schema-update load path so a
runtime reservation provider that resolves to null is treated as unset, and the
job is submitted without an explicit reservation, matching loadJobProjectId.
Empty strings remain invalid, consistent with the String overload. I added a
test for the unset runtime-provider case; the targeted tests pass.
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]