Class CachedSideInputReader
java.lang.Object
org.apache.beam.runners.spark.structuredstreaming.translation.batch.functions.CachedSideInputReader
- All Implemented Interfaces:
org.apache.beam.runners.core.SideInputReader
@Internal
public class CachedSideInputReader
extends Object
implements org.apache.beam.runners.core.SideInputReader
SideInputReader that caches results for costly
Materializations
.
Concurrent access is not expected, but it won't impact correctness.-
Method Summary
Modifier and TypeMethodDescription<T> boolean
contains
(PCollectionView<T> view) <T> @Nullable T
get
(PCollectionView<T> view, BoundedWindow window) boolean
isEmpty()
static org.apache.beam.runners.core.SideInputReader
of
(org.apache.beam.runners.core.SideInputReader reader, Collection<PCollectionView<?>> views) Creates a SideInputReader that caches results for costlyMaterializations
if present, otherwise the SideInputReader is returned as is.
-
Method Details
-
of
public static org.apache.beam.runners.core.SideInputReader of(org.apache.beam.runners.core.SideInputReader reader, Collection<PCollectionView<?>> views) Creates a SideInputReader that caches results for costlyMaterializations
if present, otherwise the SideInputReader is returned as is. Concurrent access is not expected, but it won't impact correctness. -
get
- Specified by:
get
in interfaceorg.apache.beam.runners.core.SideInputReader
-
contains
- Specified by:
contains
in interfaceorg.apache.beam.runners.core.SideInputReader
-
isEmpty
public boolean isEmpty()- Specified by:
isEmpty
in interfaceorg.apache.beam.runners.core.SideInputReader
-