Class StoreSettings

    • Constructor Detail

      • StoreSettings

        public StoreSettings​(Application application)
        Construct.
        Parameters:
        application -
    • Method Detail

      • getMaxSizePerSession

        public org.apache.wicket.util.lang.Bytes getMaxSizePerSession()
        Returns:
        maximum page size. After this size is exceeded, the DiskPageStore will start saving the pages at the beginning of file.
      • setMaxSizePerSession

        public StoreSettings setMaxSizePerSession​(org.apache.wicket.util.lang.Bytes maxSizePerSession)
        Sets the maximum size of the File where page instances per session are stored. After reaching this size the DiskPageStore will start overriding the oldest pages at the beginning of the file.
        Parameters:
        maxSizePerSession - the maximum size of the file where page instances are stored per session. In bytes.
        Returns:
        this object for chaining
      • getFileStoreFolder

        public File getFileStoreFolder()
        Returns:
        the location of the folder where DiskPageStore will store the files with page instances per session
      • setFileStoreFolder

        public StoreSettings setFileStoreFolder​(File fileStoreFolder)
        Sets the folder where DiskPageStore will store the files with page instances per session
        Parameters:
        fileStoreFolder - the new location
        Returns:
        this object for chaining
      • getAsynchronousQueueCapacity

        public int getAsynchronousQueueCapacity()
        Returns:
        the capacity of the queue used to store the pages which will be stored asynchronously
        See Also:
        AsynchronousPageStore
      • setAsynchronousQueueCapacity

        public StoreSettings setAsynchronousQueueCapacity​(int queueCapacity)
        Sets the capacity of the queue used to store the pages which will be stored asynchronously
        Parameters:
        queueCapacity - the capacity of the queue
        Returns:
        this object for chaining
        See Also:
        AsynchronousPageStore
      • setAsynchronous

        public StoreSettings setAsynchronous​(boolean async)
        Sets a flag whether to wrap the configured IPageStore with AsynchronousPageStore. By doing this the HTTP worker thread will not wait for the actual write of the page's bytes into the wrapped IPageStore.
        Parameters:
        async - true to make it asynchronous, false - otherwise
        Returns:
        this object for chaining
      • isAsynchronous

        public boolean isAsynchronous()
        Returns:
        true if the storing of page is asynchronous
      • setEncrypted

        public StoreSettings setEncrypted​(boolean encrypted)
        Sets a flag whether to wrap the configured IPageStore with CryptingPageStore.
        Parameters:
        encrypted - true to encrypt, false - otherwise
        Returns:
        this object for chaining
      • isEncrypted

        public boolean isEncrypted()
        Returns:
        true if the storing of page is encrypted