Skip to content

Instantly share code, notes, and snippets.

View RustedBones's full-sized avatar

Michel Davit RustedBones

View GitHub Profile
@RustedBones
RustedBones / BigqueryClientTestIT.scala
Created October 24, 2023 08:21
BQ ReadSession selectedFields on null record coalesced to 0 value
package com.example
import com.google.api.gax.core.FixedCredentialsProvider
import com.google.api.gax.rpc.FixedHeaderProvider
import com.google.cloud.bigquery.storage.v1.{BigQueryReadClient, BigQueryReadSettings, CreateReadSessionRequest, DataFormat, ReadRowsRequest, ReadSession}
import org.apache.avro.Schema
import org.apache.avro.generic.{GenericDatumReader, GenericRecord}
import org.apache.avro.io.DecoderFactory
import org.scalatest.flatspec.AnyFlatSpec
import org.scalatest.matchers.should.Matchers