[
https://issues.apache.org/jira/browse/BEAM-7721?focusedWorklogId=288843&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-288843
]
ASF GitHub Bot logged work on BEAM-7721:
----------------------------------------
Author: ASF GitHub Bot
Created on: 05/Aug/19 10:32
Start Date: 05/Aug/19 10:32
Worklog Time Spent: 10m
Work Description: mwalenia commented on pull request #9041: [BEAM-7721]
Add a new module with BigQuery IO Read performance test
URL: https://github.com/apache/beam/pull/9041#discussion_r310539188
##########
File path:
sdks/java/io/bigquery-io-perf-tests/src/test/java/org/apache/beam/sdk/bigqueryioperftests/BigQueryIOReadPerformanceIT.java
##########
@@ -0,0 +1,205 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.beam.sdk.bigqueryioperftests;
+
+import com.google.api.services.bigquery.model.TableFieldSchema;
+import com.google.api.services.bigquery.model.TableRow;
+import com.google.api.services.bigquery.model.TableSchema;
+import com.google.cloud.Timestamp;
+import com.google.cloud.bigquery.BigQuery;
+import com.google.cloud.bigquery.BigQuery.TableOption;
+import com.google.cloud.bigquery.BigQueryOptions;
+import com.google.cloud.bigquery.Table;
+import com.google.cloud.bigquery.TableId;
+import java.io.IOException;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.UUID;
+import java.util.function.Function;
+import org.apache.beam.sdk.Pipeline;
+import org.apache.beam.sdk.PipelineResult;
+import org.apache.beam.sdk.io.Read;
+import org.apache.beam.sdk.io.common.IOITHelper;
+import org.apache.beam.sdk.io.common.IOTestPipelineOptions;
+import org.apache.beam.sdk.io.gcp.bigquery.BigQueryIO;
+import org.apache.beam.sdk.io.synthetic.SyntheticBoundedSource;
+import org.apache.beam.sdk.io.synthetic.SyntheticOptions;
+import org.apache.beam.sdk.io.synthetic.SyntheticSourceOptions;
+import org.apache.beam.sdk.options.Description;
+import org.apache.beam.sdk.options.Validation;
+import org.apache.beam.sdk.options.ValueProvider;
+import org.apache.beam.sdk.testutils.NamedTestResult;
+import org.apache.beam.sdk.testutils.metrics.IOITMetrics;
+import org.apache.beam.sdk.testutils.metrics.MetricsReader;
+import org.apache.beam.sdk.testutils.metrics.TimeMonitor;
+import org.apache.beam.sdk.transforms.DoFn;
+import org.apache.beam.sdk.transforms.ParDo;
+import org.apache.beam.sdk.values.KV;
+import org.junit.AfterClass;
+import org.junit.BeforeClass;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.junit.runners.JUnit4;
+
+/**
+ * A performance test of {@link
org.apache.beam.sdk.io.gcp.bigquery.BigQueryIO}.
+ *
+ * <p>Usage:
+ *
+ * <pre>
+ * ./gradlew integrationTest -p sdks/java/io/gcp/bigquery
-DintegrationTestPipelineOptions='[
+ * "--bigQuerySourceDataset=source-dataset",
+ * "--bigQuerySourceTable=source-table",
+ * "--bigQueryDataset=metrics-dataset",
+ * "--bigQueryTable=metrics-table",
+ * "--sourceOptions={"numRecords":"1000", "keySize":1, valueSize:"1024"}
+ * }"]'
+ * --tests org.apache.beam.sdk.io.gcp.bigQuery.BigQueryIOReadPerformanceIT
+ * -DintegrationTestRunner=direct
+ * </pre>
+ */
+@RunWith(JUnit4.class)
+public class BigQueryIOReadPerformanceIT {
Review comment:
Yes, in light of future changes this name would make more sense. I'll change
it in another PR.
----------------------------------------------------------------
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]
Issue Time Tracking
-------------------
Worklog Id: (was: 288843)
Time Spent: 2h 40m (was: 2.5h)
> Measure throughput in BigQueryIO read in Java
> ---------------------------------------------
>
> Key: BEAM-7721
> URL: https://issues.apache.org/jira/browse/BEAM-7721
> Project: Beam
> Issue Type: Improvement
> Components: testing
> Reporter: Michal Walenia
> Assignee: Michal Walenia
> Priority: Major
> Time Spent: 2h 40m
> Remaining Estimate: 0h
>
> Collect bytes/time metric in BQ read tests in Java SDK
--
This message was sent by Atlassian JIRA
(v7.6.14#76016)