Uploaded image for project: 'Commons JCS'
  1. Commons JCS
  2. JCS-147

Provide file size limitation for Block Disk Cache and Indexed Disk Cache

    XMLWordPrintableJSON

    Details

      Description

      Attached please find a patch, that provides additional mode of operation to Block and Index Disk Caches, i.e. that instead of limiting the key count, you limit the content size. It's a proxy for limiting the file size, but it works quite good.

      The patch has additional length, as I moved:
      src/main/java/org/apache/commons/jcs/utils/struct/LRUMap.java
      to:
      src/main/java/org/apache/commons/jcs/utils/struct/AbstractLRUMap.java

      and then - created LRUMap, that implements size-based policy.

      Also, in a separate file I provided update for website docs.

      I did some testing, also performance, and it looks like, it doesn't introduce noticeable difference.

        Attachments

        1. xdocs.patch
          2 kB
          Wiktor N
        2. jcs-diskfile-limits.patch
          105 kB
          Wiktor N

          Activity

            People

            • Assignee:
              tv Thomas Vandahl
              Reporter:
              wiktorn Wiktor N
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: