Interface AdvancedCacheWriter<K,V>

All Superinterfaces:
CacheWriter<K,V>, Lifecycle
All Known Subinterfaces:
AdvancedCacheExpirationWriter<K,V>, AdvancedLoadWriteStore<K,V>, SegmentedAdvancedLoadWriteStore<K,V>, TransactionalCacheWriter<K,V>
All Known Implementing Classes:
AbstractSegmentedAdvancedLoadWriteStore, ComposedSegmentedLoadWriteStore

@ThreadSafe @Deprecated(forRemoval=true) public interface AdvancedCacheWriter<K,V> extends CacheWriter<K,V>
Deprecated, for removal: This API element is subject to removal in a future version.
since 11.0 replaced by NonBlockingStore
Defines advanced functionality for persisting data to an external storage.
Since:
6.0
Author:
Mircea Markus
  • Method Details

    • clear

      void clear()
      Deprecated, for removal: This API element is subject to removal in a future version.
      Removes all the data from the storage.
      Throws:
      PersistenceException - in case of an error, e.g. communicating with the external storage
    • purge

      void purge(Executor threadPool, AdvancedCacheWriter.PurgeListener<? super K> listener)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Using the thread in the pool, removed all the expired data from the persistence storage. For each removed entry, the supplied listener is invoked.

      When this method returns all entries will be purged and no tasks will be running due to this loader in the provided executor. If however an exception is thrown there could be tasks still pending or running in the executor.

      Throws:
      PersistenceException - in case of an error, e.g. communicating with the external storage