public class BeamPCollectionTable extends BaseBeamTable
BeamPCollectionTable
converts a PCollection<BeamSqlRow>
as a virtual table,
then a downstream query can query directly.beamSqlRowType
Modifier | Constructor and Description |
---|---|
protected |
BeamPCollectionTable(BeamRecordSqlType beamSqlRowType) |
|
BeamPCollectionTable(PCollection<BeamRecord> upstream,
BeamRecordSqlType beamSqlRowType) |
Modifier and Type | Method and Description |
---|---|
PCollection<BeamRecord> |
buildIOReader(Pipeline pipeline)
create a
PCollection<BeamSqlRow> from source. |
PTransform<? super PCollection<BeamRecord>,PDone> |
buildIOWriter()
create a
IO.write() instance to write to target. |
BeamIOType |
getSourceType()
In Beam SQL, there's no difference between a batch query and a streaming
query.
|
getRowType
protected BeamPCollectionTable(BeamRecordSqlType beamSqlRowType)
public BeamPCollectionTable(PCollection<BeamRecord> upstream, BeamRecordSqlType beamSqlRowType)
public BeamIOType getSourceType()
BeamSqlTable
BeamIOType
is used to validate the sources.public PCollection<BeamRecord> buildIOReader(Pipeline pipeline)
BeamSqlTable
PCollection<BeamSqlRow>
from source.public PTransform<? super PCollection<BeamRecord>,PDone> buildIOWriter()
BeamSqlTable
IO.write()
instance to write to target.