[ https://issues.apache.org/jira/browse/BEAM-8895?focusedWorklogId=354237&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-354237 ]
ASF GitHub Bot logged work on BEAM-8895: ---------------------------------------- Author: ASF GitHub Bot Created on: 05/Dec/19 12:17 Start Date: 05/Dec/19 12:17 Worklog Time Spent: 10m Work Description: lgajowy commented on pull request #10294: [BEAM-8895] Add BigQuery table name sanitization to BigQueryIOIT URL: https://github.com/apache/beam/pull/10294#discussion_r354279165 ########## File path: sdks/java/io/bigquery-io-perf-tests/src/test/java/org/apache/beam/sdk/bigqueryioperftests/BigQueryIOIT.java ########## @@ -101,6 +101,8 @@ public static void setup() throws IOException { metricsBigQueryTable = options.getMetricsBigQueryTable(); testBigQueryDataset = options.getTestBigQueryDataset(); testBigQueryTable = String.format("%s_%s", options.getTestBigQueryTable(), TEST_ID); + // BigQuery table names must contain only alphanumerics and underscores + testBigQueryTable = testBigQueryTable.replace("[^A-Za-z0-9_]+", ""); Review comment: Other than that I would avoid leaving a comment and assigning the variable twice. Rather than that, it would be better to have a well-named method encapsulating the behavior. ---------------------------------------------------------------- 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: us...@infra.apache.org Issue Time Tracking ------------------- Worklog Id: (was: 354237) Time Spent: 50m (was: 40m) > BigQueryIO streaming test on Java is flaky > ------------------------------------------ > > Key: BEAM-8895 > URL: https://issues.apache.org/jira/browse/BEAM-8895 > Project: Beam > Issue Type: Bug > Components: testing > Reporter: Kamil Wasilewski > Assignee: Michal Walenia > Priority: Major > Fix For: Not applicable > > Time Spent: 50m > Remaining Estimate: 0h > > {code:java} > SEVERE: 2019-12-05T06:57:31.089Z: java.lang.RuntimeException: > com.google.api.client.googleapis.json.GoogleJsonResponseException: 400 Bad > Request > 07:57:32 { > 07:57:32 "code" : 400, > 07:57:32 "errors" : [ { > 07:57:32 "domain" : "global", > 07:57:32 "message" : "Invalid table ID > \"bqio_write_10GB_java_e27dc010-6896-41ac-90f3-25b5adc58617\". Table IDs must > be alphanumeric (plus underscores) and must be at most 1024 characters long. > Also, Table decorators cannot be used.", > 07:57:32 "reason" : "invalid" > 07:57:32 } ], > 07:57:32 "message" : "Invalid table ID > \"bqio_write_10GB_java_e27dc010-6896-41ac-90f3-25b5adc58617\". Table IDs must > be alphanumeric (plus underscores) and must be at most 1024 characters long. > Also, Table decorators cannot be used.", > 07:57:32 "status" : "INVALID_ARGUMENT" > 07:57:32 } > {code} -- This message was sent by Atlassian Jira (v8.3.4#803005)