Interface OFreezableStorageComponent

All Known Subinterfaces:
OLuceneIndexEngine
All Known Implementing Classes:
OAbstractPaginatedStorage, ODirectMemoryStorage, OLocalPaginatedStorage, OLuceneFullTextIndexEngine, OLuceneGeoSpatialIndexEngine, OLuceneIndexEngineAbstract, OLuceneLegacySpatialIndexEngine, OLuceneSpatialIndexEngineAbstract, OLuceneSpatialIndexEngineDelegator

public interface OFreezableStorageComponent
Interface for storage components that support freeze/release operations.
Since:
1.5.1
Author:
Artem Orobets (enisher-at-gmail.com)
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    freeze(boolean throwException)
    After this method finished it's execution, all threads that are going to perform data modifications in storage should wait till release() method will be called.
    void
    After this method finished execution all threads that are waiting to perform data modifications in storage will be awaken and will be allowed to continue their execution.
  • Method Details

    • freeze

      void freeze(boolean throwException)
      After this method finished it's execution, all threads that are going to perform data modifications in storage should wait till release() method will be called. This method will wait till all ongoing modifications will be finished.
      Parameters:
      throwException - If true OModificationOperationProhibitedException exception will be thrown on call of methods that requires storage modification. Otherwise other threads will wait for release() method call.
    • release

      void release()
      After this method finished execution all threads that are waiting to perform data modifications in storage will be awaken and will be allowed to continue their execution.