Class ReadOnlyLocalTableLocation
- All Implemented Interfaces:
com.fishlib.base.log.LogOutputAppendable,DeephavenFormatTableLocation<LocalColumnLocation>,TableLocation<LocalColumnLocation>,TableLocationKey,TableLocationState,NamedImplementation
public class ReadOnlyLocalTableLocation extends LocalTableLocation
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.illumon.iris.db.v2.locations.TableLocation
TableLocation.Format, TableLocation.ListenerNested classes/interfaces inherited from interface com.illumon.iris.db.v2.locations.TableLocationKey
TableLocationKey.ComparatorImpl, TableLocationKey.KeyedObjectKeyImpl<VALUE_TYPE>, TableLocationKey.SelfKeyedObjectKeyImpl<VALUE_TYPE extends TableLocationKey> -
Field Summary
Fields inherited from interface com.illumon.iris.db.v2.locations.TableLocationKey
COMPARATOR, NULL_PARTITIONFields inherited from interface com.illumon.iris.db.v2.locations.TableLocationState
NULL_SIZE, NULL_TIME -
Method Summary
Modifier and Type Method Description protected voidactivateUnderlyingDataSource()Refresh and activate update pushing from the implementing class.protected voiddeactivateUnderlyingDataSource()Deactivate pushed updates from the implementing class.StringgetImplementationName()Get a name for the implementing class.protected <T> booleanmatchSubscriptionToken(T token)Verify that a notification pertains to a currently-active subscription.voidrefresh()Initialize or refresh state information.Methods inherited from class com.illumon.iris.db.v2.locations.local.LocalTableLocation
ensureReaderCheckpointInitialized, getCheckpointRecordFile, getColumnVersion, getDataIndex, getDirectory, getReaderCheckpointRecord, getSortedColumns, hasDataIndexFor, makeColumnLocation, readCheckpointRecordForImporters, readCheckpointRecordForImporters, readCheckpointRecordForImporters, readCheckpointRecordForImportersFromFile, readCheckpointRecordForImportersFromFile, refreshReaderCheckpointRecord, setSnapshot, writeCheckpointRecordMethods inherited from class com.illumon.iris.db.v2.locations.AbstractTableLocation
clearColumnLocations, deliverInitialSnapshot, getColumnLocation, getColumnPartition, getInternalPartition, getLastModifiedTimeMillis, getSize, getStateLock, getTableKey, handleUpdate, handleUpdate, toStringMethods inherited from class com.illumon.iris.db.v2.locations.SubscriptionAggregator
activationFailed, activationSuccessful, checkHasSubscribers, postActivationHook, subscribe, supportsSubscriptions, unsubscribeMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface com.illumon.iris.db.v2.locations.DeephavenFormatTableLocation
getFormatMethods inherited from interface com.illumon.iris.db.v2.locations.TableLocation
append, getColumnLocation, getTableKey, subscribe, supportsSubscriptions, toGenericString, toStringDetailed, toStringHelper, unsubscribeMethods inherited from interface com.illumon.iris.db.v2.locations.TableLocationKey
getColumnPartition, getInternalPartition, writeToMethods inherited from interface com.illumon.iris.db.v2.locations.TableLocationState
copyStateValuesTo, getLastModifiedTimeMillis, getSize, getStateLock, writeStateValuesTo
-
Method Details
-
getImplementationName
Description copied from interface:NamedImplementationGet a name for the implementing class. Useful for abstract classes that implement
LogOutputAppendableor overridetoString.The default implementation is correct, but not suitable for high-frequency usage.
- Returns:
- A name for the implementing class
-
refresh
public void refresh()Description copied from interface:TableLocationInitialize or refresh state information. -
activateUnderlyingDataSource
protected void activateUnderlyingDataSource()Description copied from class:SubscriptionAggregatorRefresh and activate update pushing from the implementing class.
If the implementation will deliver notifications in a different thread than the one that calls this method, then this method must be asynchronous - that is, it must not block pending delivery of results. This requirement holds even if that other thread has nothing to do with the initial activation request!
Listeners should guard against duplicate notifications, especially if the implementation delivers synchronous notifications.
The implementation should call activationSuccessful() when done activating and delivering initial refresh results, unless activationFailed() was called instead.
Must be called under the subscription lock.
- Overrides:
activateUnderlyingDataSourcein classSubscriptionAggregator<TableLocation.Listener>
-
deactivateUnderlyingDataSource
protected void deactivateUnderlyingDataSource()Description copied from class:SubscriptionAggregatorDeactivate pushed updates from the implementing class. Must be called under the subscription lock.- Overrides:
deactivateUnderlyingDataSourcein classSubscriptionAggregator<TableLocation.Listener>
-
matchSubscriptionToken
protected <T> boolean matchSubscriptionToken(T token)Description copied from class:SubscriptionAggregatorVerify that a notification pertains to a currently-active subscription. Must be called under the subscription lock.- Overrides:
matchSubscriptionTokenin classSubscriptionAggregator<TableLocation.Listener>- Parameters:
token- A subscription-related object that the subclass can use to match a notification- Returns:
- True iff notification delivery should proceed
-