Specifying the Ehcache Cache Path

  • Last update:January 26, 2024
  • Overview

    Problem

    The .FineReport110 folder, in which all files are generated by the server, exists in the root directory of the system.

    In this folder, the ./ehcache_disk_store file occupies a large space, causing the capacity of the root directory to be easily reached. This document introduces how to modify the storage path of the ./ehcache_disk_store file.

     1.png

    Implementation Method

    The ./ehcache_disk_store file contains two types of cache files: database level-2 cache files and file server cache files.

    You need to separately modify the paths of two types of cache files, rather than directly modify the path of ./ehcache_disk_store.

    Operation Method

    Modification of the Database Level-2 Cache Path

    1. Create a file named ehcache.db.properties in the WEB-INF/config folder of the project directory.

    Configurations related to the database level-2 cache path are shown in the boxed part of the following figure. You can modify values as needed.

    You can download and unzip the sample file ehcache.db.zip.

    2. The path takes effect after you restart the project. The original file can be discarded and manually deleted.

     2.png

    Modification of the File Server Cache Path

    Add the following two fields to the fine_conf_entity table in FineDB.

    Field
    Value

    ResourceCacheConfig.persistenceStrategy

    LOCALTEMPSWAP

    ResourceCacheManagerConfig.diskStorePath

    diskStore=C:\\Users\\root\\Desktop\\tmp\\resource_cache


    Attachment List


    Theme: Performance Optimization
    • Helpful
    • Not helpful
    • Only read

    滑鼠選中內容,快速回饋問題

    滑鼠選中存在疑惑的內容,即可快速回饋問題,我們將會跟進處理。

    不再提示

    10s後關閉

    Get
    Help
    Online Support
    Professional technical support is provided to quickly help you solve problems.
    Online support is available from 9:00-12:00 and 13:30-17:30 on weekdays.
    Page Feedback
    You can provide suggestions and feedback for the current web page.
    Pre-Sales Consultation
    Business Consultation
    Business: international@fanruan.com
    Support: support@fanruan.com
    Page Feedback
    *Problem Type
    Cannot be empty
    Problem Description
    0/1000
    Cannot be empty

    Submitted successfully

    Network busy