public abstract static class AvroIO.ReadFiles<T>
extends org.apache.beam.sdk.transforms.PTransform<org.apache.beam.sdk.values.PCollection<org.apache.beam.sdk.io.FileIO.ReadableFile>,org.apache.beam.sdk.values.PCollection<T>>
AvroIO.readFiles(java.lang.Class<T>).| Constructor and Description |
|---|
ReadFiles() |
| Modifier and Type | Method and Description |
|---|---|
org.apache.beam.sdk.values.PCollection<T> |
expand(org.apache.beam.sdk.values.PCollection<org.apache.beam.sdk.io.FileIO.ReadableFile> input) |
void |
populateDisplayData(org.apache.beam.sdk.transforms.display.DisplayData.Builder builder) |
AvroIO.ReadFiles<T> |
withBeamSchemas(boolean withBeamSchemas)
If set to true, a Beam schema will be inferred from the AVRO schema.
|
AvroIO.ReadFiles<T> |
withCoder(org.apache.beam.sdk.coders.Coder<T> coder)
Sets a coder for the result of the read function.
|
AvroIO.ReadFiles<T> |
withDatumReaderFactory(AvroSource.DatumReaderFactory<T> factory)
Sets a custom
AvroSource.DatumReaderFactory for reading. |
AvroIO.ReadFiles<T> |
withDesiredBundleSizeBytes(long desiredBundleSizeBytes)
Set a value for the bundle size for parallel reads.
|
AvroIO.ReadFiles<T> |
withFileExceptionHandler(org.apache.beam.sdk.io.ReadAllViaFileBasedSource.ReadFileRangesFnExceptionHandler exceptionHandler)
Specifies if exceptions should be logged only for streaming pipelines.
|
AvroIO.ReadFiles<T> |
withUsesReshuffle(boolean usesReshuffle)
Specifies if a Reshuffle should run before file reads occur.
|
public AvroIO.ReadFiles<T> withDesiredBundleSizeBytes(long desiredBundleSizeBytes)
public AvroIO.ReadFiles<T> withUsesReshuffle(boolean usesReshuffle)
public AvroIO.ReadFiles<T> withFileExceptionHandler(org.apache.beam.sdk.io.ReadAllViaFileBasedSource.ReadFileRangesFnExceptionHandler exceptionHandler)
public AvroIO.ReadFiles<T> withBeamSchemas(boolean withBeamSchemas)
public AvroIO.ReadFiles<T> withCoder(org.apache.beam.sdk.coders.Coder<T> coder)
public AvroIO.ReadFiles<T> withDatumReaderFactory(AvroSource.DatumReaderFactory<T> factory)
AvroSource.DatumReaderFactory for reading. Pass a AvroDatumFactory to also use the factory for the default output AvroCoderpublic org.apache.beam.sdk.values.PCollection<T> expand(org.apache.beam.sdk.values.PCollection<org.apache.beam.sdk.io.FileIO.ReadableFile> input)
expand in class org.apache.beam.sdk.transforms.PTransform<org.apache.beam.sdk.values.PCollection<org.apache.beam.sdk.io.FileIO.ReadableFile>,org.apache.beam.sdk.values.PCollection<T>>public void populateDisplayData(org.apache.beam.sdk.transforms.display.DisplayData.Builder builder)
populateDisplayData in interface org.apache.beam.sdk.transforms.display.HasDisplayDatapopulateDisplayData in class org.apache.beam.sdk.transforms.PTransform<org.apache.beam.sdk.values.PCollection<org.apache.beam.sdk.io.FileIO.ReadableFile>,org.apache.beam.sdk.values.PCollection<T>>