Skip to content

Commit ec0c417

Browse files
committed
fix merge
1 parent 54e60f5 commit ec0c417

1 file changed

Lines changed: 8 additions & 61 deletions

File tree

java-bigquery/google-cloud-bigquery-jdbc/src/main/java/com/google/cloud/bigquery/jdbc/BigQueryConnection.java

Lines changed: 8 additions & 61 deletions
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,9 @@ public class BigQueryConnection extends BigQueryNoOpsConnection {
142142
Long connectionPoolSize;
143143
Long listenerPoolSize;
144144
String partnerToken;
145+
DatabaseMetaData databaseMetaData;
146+
Boolean reqGoogleDriveScope;
147+
private boolean isReadOnlyTokenUsed = false;
145148
private int queryTaskThreadCount;
146149
private ExecutorService queryTaskExecutor;
147150

@@ -269,68 +272,12 @@ public class BigQueryConnection extends BigQueryNoOpsConnection {
269272

270273
this.headerProvider = createHeaderProvider();
271274
this.bigQuery = getBigQueryConnection();
275+
276+
this.queryTaskThreadCount = ds.getQueryTaskThreadCount();
277+
this.queryTaskExecutor =
278+
Executors.newFixedThreadPool(
279+
this.queryTaskThreadCount, new BigQueryThreadFactory("BigQuery-query-task-"));
272280
}
273-
this.location = ds.getLocation();
274-
this.enableHighThroughputAPI = ds.getEnableHighThroughputAPI();
275-
this.highThroughputMinTableSize = ds.getHighThroughputMinTableSize();
276-
this.highThroughputActivationRatio = ds.getHighThroughputActivationRatio();
277-
this.useQueryCache = ds.getUseQueryCache();
278-
this.useStatelessQueryMode = ds.getUseStatelessQueryMode();
279-
280-
this.queryDialect = ds.getQueryDialect();
281-
this.allowLargeResults = ds.getAllowLargeResults();
282-
this.destinationTable = ds.getDestinationTable();
283-
this.destinationDataset = ds.getDestinationDataset();
284-
this.destinationDatasetExpirationTime = ds.getDestinationDatasetExpirationTime();
285-
this.kmsKeyName = ds.getKmsKeyName();
286-
Map<String, String> proxyProperties =
287-
BigQueryJdbcProxyUtility.parseProxyProperties(ds, this.connectionClassName);
288-
289-
this.sslTrustStorePath = ds.getSSLTrustStorePath();
290-
this.sslTrustStorePassword = ds.getSSLTrustStorePassword();
291-
this.httpConnectTimeout = ds.getHttpConnectTimeout();
292-
this.httpReadTimeout = ds.getHttpReadTimeout();
293-
294-
this.httpTransportOptions =
295-
BigQueryJdbcProxyUtility.getHttpTransportOptions(
296-
proxyProperties,
297-
this.sslTrustStorePath,
298-
this.sslTrustStorePassword,
299-
this.httpConnectTimeout,
300-
this.httpReadTimeout,
301-
this.connectionClassName);
302-
this.transportChannelProvider =
303-
BigQueryJdbcProxyUtility.getTransportChannelProvider(
304-
proxyProperties,
305-
this.sslTrustStorePath,
306-
this.sslTrustStorePassword,
307-
this.connectionClassName);
308-
this.enableSession = ds.getEnableSession();
309-
this.unsupportedHTAPIFallback = ds.getUnsupportedHTAPIFallback();
310-
this.maxResults = ds.getMaxResults();
311-
Map<String, String> queryPropertiesMap = ds.getQueryProperties();
312-
this.sessionInfoConnectionProperty = getSessionPropertyFromQueryProperties(queryPropertiesMap);
313-
this.queryProperties = convertMapToConnectionPropertiesList(queryPropertiesMap);
314-
this.enableWriteAPI = ds.getEnableWriteAPI();
315-
this.writeAPIActivationRowCount = ds.getSwaActivationRowCount();
316-
this.writeAPIAppendRowCount = ds.getSwaAppendRowCount();
317-
318-
this.additionalProjects = ds.getAdditionalProjects();
319-
320-
this.filterTablesOnDefaultDataset = ds.getFilterTablesOnDefaultDataset();
321-
this.requestGoogleDriveScope = ds.getRequestGoogleDriveScope();
322-
this.metadataFetchThreadCount = ds.getMetadataFetchThreadCount();
323-
this.queryTaskThreadCount = ds.getQueryTaskThreadCount();
324-
this.queryTaskExecutor =
325-
Executors.newFixedThreadPool(
326-
this.queryTaskThreadCount, new BigQueryThreadFactory("BigQuery-query-task-"));
327-
this.requestReason = ds.getRequestReason();
328-
this.connectionPoolSize = ds.getConnectionPoolSize();
329-
this.listenerPoolSize = ds.getListenerPoolSize();
330-
this.partnerToken = ds.getPartnerToken();
331-
332-
this.headerProvider = createHeaderProvider();
333-
this.bigQuery = getBigQueryConnection();
334281
}
335282

336283
String getLibraryVersion(Class<?> libraryClass) {

0 commit comments

Comments
 (0)