• PDF


    • PDF

    Article summary

    ICAP server caching

    From Halo version v2.4.12, the ICAP server now includes the capability to cache adapted files for later use, speeding up the process of serving common files that have been previously rebuilt via the Halo CDR process.

    The cache is implemented and maintained by the ICAP server (icap-server) and is backed by Halo's file storage mechanism.

    Once the cache is full, the oldest items are deleted.

    The cache only persists files that have been adapted with a valid response from Halo. This includes rebuilt files, and files that failed to be rebuilt but were analyzed. All other files skip the cache; this includes bypassed, blocked and errored files.

    Cache size

    The ICAP cache is a fixed size of 1 GB, this size has been selected for ease of maintenance and I/O performance.

    Cache deployment

    Please follow the relevant deployment instructions for icap-server, which includes the cache. Please note, the cache is automatically emptied when icap-server is upgraded or installed.

    Clearing the cache

    The cache is automatically emptied when installing or upgrading the ICAP server, but there may be a reason to clear the cache at another time. Please follow the steps below to empty the cache.

    Step 1 - Connect to the ICAP server inside the Halo cluster

    Using Kubectl, the following command opens a connection to the icap-server-api service in the cdrplatform namespace by forwarding to the exposed port 8080.

    kubectl port-forward service/icap-server-api <local-port>:8080 -n cdrplatform

    Step 2 - Make a DELETE request on the exposed port

    For convenience, the icap-server ships with an API for maintaining the cache. The port that was opened in the last step can now be used to clear the cache.

    curl --location --request DELETE 'http://localhost:<local-port>/api/v1/cache'

    Was this article helpful?

    What's Next