File tree Expand file tree Collapse file tree 2 files changed +9
-6
lines changed
google-cloud-bigquery/src/main/java/com/google/cloud/bigquery/spi/v2 Expand file tree Collapse file tree 2 files changed +9
-6
lines changed Original file line number Diff line number Diff line change @@ -60,13 +60,13 @@ implementation 'com.google.cloud:google-cloud-bigquery'
6060If you are using Gradle without BOM, add this to your dependencies:
6161
6262``` Groovy
63- implementation 'com.google.cloud:google-cloud-bigquery:2.25 .0'
63+ implementation 'com.google.cloud:google-cloud-bigquery:2.26 .0'
6464```
6565
6666If you are using SBT, add this to your dependencies:
6767
6868``` Scala
69- libraryDependencies += " com.google.cloud" % " google-cloud-bigquery" % " 2.25 .0"
69+ libraryDependencies += " com.google.cloud" % " google-cloud-bigquery" % " 2.26 .0"
7070```
7171<!-- {x-version-update-end} -->
7272
@@ -348,7 +348,7 @@ Java is a registered trademark of Oracle and/or its affiliates.
348348[ kokoro-badge-link-5 ] : http://storage.googleapis.com/cloud-devrel-public/java/badges/java-bigquery/java11.html
349349[ stability-image ] : https://img.shields.io/badge/stability-stable-green
350350[ maven-version-image ] : https://img.shields.io/maven-central/v/com.google.cloud/google-cloud-bigquery.svg
351- [ maven-version-link ] : https://central.sonatype.com/artifact/com.google.cloud/google-cloud-bigquery/2.25 .0
351+ [ maven-version-link ] : https://central.sonatype.com/artifact/com.google.cloud/google-cloud-bigquery/2.26 .0
352352[ authentication ] : https://github.com/googleapis/google-cloud-java#authentication
353353[ auth-scopes ] : https://developers.google.com/identity/protocols/oauth2/scopes
354354[ predefined-iam-roles ] : https://cloud.google.com/iam/docs/understanding-roles#predefined_roles
Original file line number Diff line number Diff line change 7777public class HttpBigQueryRpc implements BigQueryRpc {
7878
7979 public static final String DEFAULT_PROJECTION = "full" ;
80- private static final String BASE_RESUMABLE_URI =
81- "https://www.googleapis.com/upload/bigquery/v2/projects/" ;
80+ private static final String BASE_RESUMABLE_URI = "upload/bigquery/v2/projects/" ;
8281 // see:
8382 // https://cloud.google.com/bigquery/loading-data-post-request#resume-upload
8483 private static final int HTTP_RESUME_INCOMPLETE = 308 ;
@@ -725,7 +724,11 @@ public QueryResponse queryRpc(String projectId, QueryRequest content) {
725724 @ Override
726725 public String open (Job loadJob ) {
727726 try {
728- String builder = BASE_RESUMABLE_URI + options .getProjectId () + "/jobs" ;
727+ String builder = options .getHost ();
728+ if (!builder .endsWith ("/" )) {
729+ builder += "/" ;
730+ }
731+ builder += BASE_RESUMABLE_URI + options .getProjectId () + "/jobs" ;
729732 GenericUrl url = new GenericUrl (builder );
730733 url .set ("uploadType" , "resumable" );
731734 JsonFactory jsonFactory = bigquery .getJsonFactory ();
You can’t perform that action at this time.
0 commit comments