diff options
| author | Sho Sakuma <me@m1sk9.dev> | 2026-02-23 18:57:05 +0900 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2026-02-23 18:57:05 +0900 |
| commit | f56d42a478c0dfefe8b2a5d73e483d0ad11e1e89 (patch) | |
| tree | 70f28be9cec5a06eec88a6049fe374c85ed0f5d2 /docs/src/en/admin-guide/cache.md | |
| parent | 59a7e742fe52afba246ff2e4dce9753dd1468e05 (diff) | |
| parent | 58cd5abbbf258dee0c6aa83326ebf86076efa07e (diff) | |
| download | LunaticChat-f56d42a478c0dfefe8b2a5d73e483d0ad11e1e89.tar.gz LunaticChat-f56d42a478c0dfefe8b2a5d73e483d0ad11e1e89.tar.bz2 LunaticChat-f56d42a478c0dfefe8b2a5d73e483d0ad11e1e89.zip | |
Merge pull request #115 from m1sk9/docs/replace-oxc_and_folia
docs: Replace oxc, Add Folia guide
Diffstat (limited to 'docs/src/en/admin-guide/cache.md')
| -rw-r--r-- | docs/src/en/admin-guide/cache.md | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/docs/src/en/admin-guide/cache.md b/docs/src/en/admin-guide/cache.md new file mode 100644 index 0000000..5142a9e --- /dev/null +++ b/docs/src/en/admin-guide/cache.md @@ -0,0 +1,41 @@ +# Cache System + +LunaticChat includes a system that automatically caches phrases from Japanese romanization conversion to both memory and disk. + +For information on Japanese romanization conversion, see [here](../player-guide/japanese-romanization.md). + +## Memory Cache + +LunaticChat caches converted phrases in memory, allowing for fast responses when the same phrase is requested again. + +This cache is temporary and is saved to disk cache at server restart or at configured intervals. + +## Disk Cache + +LunaticChat periodically saves the contents of the memory cache to disk. This allows the cache contents to be retained even after server restarts. + +The file used for disk cache can be [changed in the configuration](configuration.md#cachefilepath). + +## Cache Release + +Memory cache is automatically released by the JVM's garbage collection after being cached to disk. + +Disk cache can be released by manually deleting the file. LunaticChat will recreate the cache file on restart. + +::: warning About Purge Functionality + +LunaticChat does not implement a cache purge feature. + +This is because allowing players to manipulate the host's file system is not desirable from a security perspective. + +::: + +## Cache Version + +The file used for disk cache includes a `version` field, which handles changes to the cache format due to LunaticChat version updates. + +If the version does not match, LunaticChat recognizes the cache file as **an old format cache**, ignores its contents, and recreates it in the new format. + +```json +{ "version": "1", "entries": {} } +``` |
