Package io.deephaven.engine.table.impl
Interface ColumnSourceManager
- All Superinterfaces:
LivenessReferent
- All Known Implementing Classes:
RegionedColumnSourceManager
Manager for ColumnSources in a Table.
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addLocation
(@NotNull TableLocation tableLocation) Add a table location to the list to be checked in run().Get the added locations, first the ones that have been "included" (found to exist with non-zero size) in order of inclusion, then the remainder in order of discovery.void
deliverError
(@NotNull Throwable error, TableListener.Entry entry) Advise this ColumnSourceManager that an error has occurred, and that it will no longer berefreshed
.Map<String,
? extends ColumnSource<?>> Get a map of name toColumnSource
for the column sources maintained by this manager.Get the added locations that have been found to exist and have non-zero size.Observe initial sizes for the previously added table locations, and update the managed column sources accordingly.boolean
isEmpty()
Report whether this ColumnSourceManager has no locations that have been "included" (i.e.Get the name of the column that contains theTableLocation
values fromlocationTable()
.Get the added locations that have been found to exist and have non-zero size as a table containing therow sets
for each location.refresh()
Observe size changes in the previously added table locations, and update the managed column sources accordingly.boolean
removeLocationKey
(@NotNull ImmutableTableLocationKey tableLocationKey) Remove a table location key from the sources.Get the name of the column that contains theRowSet
values fromlocationTable()
.Methods inherited from interface io.deephaven.engine.liveness.LivenessReferent
dropReference, getReferentDescription, getWeakReference, retainReference, tryRetainReference
-
Method Details
-
getColumnSources
Map<String,? extends ColumnSource<?>> getColumnSources()Get a map of name toColumnSource
for the column sources maintained by this manager.- Returns:
- An unmodifiable view of the column source map maintained by this manager.
-
addLocation
Add a table location to the list to be checked in run().- Parameters:
tableLocation
- The table location to be added
-
initialize
TrackingWritableRowSet initialize()Observe initial sizes for the previously added table locations, and update the managed column sources accordingly. Create anydata indexes
that may be derived from the locations.- Returns:
- The initial set of initially-available row keys, to be owned by the caller. This row set will have a
data indexer
populated with any data indexes that were created.
-
refresh
WritableRowSet refresh()Observe size changes in the previously added table locations, and update the managed column sources accordingly.- Returns:
- The set of added row keys, to be owned by the caller
-
deliverError
Advise this ColumnSourceManager that an error has occurred, and that it will no longer berefreshed
. This method should ensure that the error is delivered to downstreamlisteners
if appropriate.- Parameters:
error
- The error that occurredentry
- The failing node's entry, if known
-
allLocations
Collection<TableLocation> allLocations()Get the added locations, first the ones that have been "included" (found to exist with non-zero size) in order of inclusion, then the remainder in order of discovery.- Returns:
- All known locations, ordered as described
-
includedLocations
Collection<TableLocation> includedLocations()Get the added locations that have been found to exist and have non-zero size.- Returns:
- The added locations that have been found to exist and have non-zero size
-
locationTable
Table locationTable()Get the added locations that have been found to exist and have non-zero size as a table containing therow sets
for each location. May only be called afterinitialize()
. The returned table will also have columns corresponding to the partitions found in the locations, for the convenience of many downstream operations.- Returns:
- The added locations that have been found to exist and have non-zero size
-
locationColumnName
String locationColumnName()Get the name of the column that contains theTableLocation
values fromlocationTable()
.- Returns:
- The name of the location column
-
rowSetColumnName
String rowSetColumnName()Get the name of the column that contains theRowSet
values fromlocationTable()
.- Returns:
- The name of the row set column
-
isEmpty
boolean isEmpty()Report whether this ColumnSourceManager has no locations that have been "included" (i.e. found to exist with non-zero size).- Returns:
- True if there are no included locations
-
removeLocationKey
Remove a table location key from the sources.- Parameters:
tableLocationKey
- the location key being removed- Returns:
- true if the location key was actually removed
-