Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 64CD6200CFA for ; Tue, 5 Sep 2017 15:25:10 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 6372616189C; Tue, 5 Sep 2017 13:25:10 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id A7B6816189A for ; Tue, 5 Sep 2017 15:25:09 +0200 (CEST) Received: (qmail 14343 invoked by uid 500); 5 Sep 2017 13:25:07 -0000 Mailing-List: contact commits-help@beam.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@beam.apache.org Delivered-To: mailing list commits@beam.apache.org Received: (qmail 14334 invoked by uid 99); 5 Sep 2017 13:25:07 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 05 Sep 2017 13:25:07 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id E8845C9CF7 for ; Tue, 5 Sep 2017 13:25:06 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -100.001 X-Spam-Level: X-Spam-Status: No, score=-100.001 tagged_above=-999 required=6.31 tests=[RP_MATCHES_RCVD=-0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id 8vKOonnixJtP for ; Tue, 5 Sep 2017 13:25:02 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTP id 15DEC6126E for ; Tue, 5 Sep 2017 13:25:02 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id B72A3E06BF for ; Tue, 5 Sep 2017 13:25:01 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 725BD24147 for ; Tue, 5 Sep 2017 13:25:01 +0000 (UTC) Date: Tue, 5 Sep 2017 13:25:01 +0000 (UTC) From: "Vincent Spiewak (JIRA)" To: commits@beam.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (BEAM-2840) BigQueryIO write is slow/fail with a bounded source MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Tue, 05 Sep 2017 13:25:10 -0000 [ https://issues.apache.org/jira/browse/BEAM-2840?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Vincent Spiewak updated BEAM-2840: ---------------------------------- Description: BigQueryIO Writer is slow / fail if the input source is bounded. If the input source is bounded (GCS / BQ select / ...), BigQueryIO Writer use the "[Method.FILE_LOADS|https://github.com/apache/beam/blob/master/sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/bigquery/BigQueryIO.java#L1168]" instead of streaming inserts. Large amounts of input datas result in a java.lang.OutOfMemoryError / Java heap space (500 millions rows). !PrepareWrite.BatchLoads.png|thumbnail! !attachment-name.jpg|thumbnail! We cannot use "Method.STREAMING_INSERTS" or control the batchs sizes since [withMaxFilesPerBundle|https://github.com/apache/beam/blob/master/sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/bigquery/BigQueryIO.java#L1131] is private :( Someone reported a similar problem with GCS -> BQ on Stackoverflow: [Why is writing to BigQuery from a Dataflow/Beam pipeline slow?|https://stackoverflow.com/questions/45889992/why-is-writing-to-bigquery-from-a-dataflow-beam-pipeline-slow#comment78954153_45889992] was: BigQueryIO Writer is slow / fail if the input source is bounded. If the input source is bounded (GCS / BQ select / ...), BigQueryIO Writer use the "[Method.FILE_LOADS|https://github.com/apache/beam/blob/master/sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/bigquery/BigQueryIO.java#L1168]" instead of streaming inserts. Large amounts of input datas result in a java.lang.OutOfMemoryError / Java heap space (500 millions rows). !PrepareWrite.BatchLoads.png|thumbnail! We cannot use "Method.STREAMING_INSERTS" or control the batchs sizes since [withMaxFilesPerBundle|https://github.com/apache/beam/blob/master/sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/bigquery/BigQueryIO.java#L1131] is private :( Someone reported a similar problem with GCS -> BQ on Stackoverflow: [Why is writing to BigQuery from a Dataflow/Beam pipeline slow?|https://stackoverflow.com/questions/45889992/why-is-writing-to-bigquery-from-a-dataflow-beam-pipeline-slow#comment78954153_45889992] > BigQueryIO write is slow/fail with a bounded source > --------------------------------------------------- > > Key: BEAM-2840 > URL: https://issues.apache.org/jira/browse/BEAM-2840 > Project: Beam > Issue Type: Bug > Components: sdk-java-gcp > Affects Versions: 2.0.0 > Environment: Gougle Cloud Platform > Reporter: Vincent Spiewak > Assignee: Chamikara Jayalath > Attachments: PrepareWrite.BatchLoads.png > > > BigQueryIO Writer is slow / fail if the input source is bounded. > If the input source is bounded (GCS / BQ select / ...), BigQueryIO Writer use the "[Method.FILE_LOADS|https://github.com/apache/beam/blob/master/sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/bigquery/BigQueryIO.java#L1168]" instead of streaming inserts. > Large amounts of input datas result in a java.lang.OutOfMemoryError / Java heap space (500 millions rows). > !PrepareWrite.BatchLoads.png|thumbnail! > !attachment-name.jpg|thumbnail! > We cannot use "Method.STREAMING_INSERTS" or control the batchs sizes since > [withMaxFilesPerBundle|https://github.com/apache/beam/blob/master/sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/bigquery/BigQueryIO.java#L1131] is private :( > Someone reported a similar problem with GCS -> BQ on Stackoverflow: > [Why is writing to BigQuery from a Dataflow/Beam pipeline slow?|https://stackoverflow.com/questions/45889992/why-is-writing-to-bigquery-from-a-dataflow-beam-pipeline-slow#comment78954153_45889992] -- This message was sent by Atlassian JIRA (v6.4.14#64029)