Jonas Grabber created BEAM-11047:
------------------------------------
Summary: BigQuery IO: Avro INTEGER values get converted to String
objects
Key: BEAM-11047
URL: https://issues.apache.org/jira/browse/BEAM-11047
Project: Beam
Issue Type: Bug
Components: io-java-gcp
Affects Versions: 2.24.0, 2.23.0, 2.22.0
Reporter: Jonas Grabber
For some reason, `convertRequiredField` used in
`BigQueryAvroUtils.convertGenericRecordToTableRow` casts values with the Avro
`INTEGER` type to `Long`, but then converts them to `String` objects via
`toString`.
I'm quite unsure where `convertGenericRecordToTableRow` is used elsewhere, but
we use it to utilize BigQuery's Storage API reads.
I'm fairly certain this is not expected behaviour because other types are
converted properly and due to the cast to `Long` it's ensured that any values
will fit into `Long` objects anyways.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)