mirror of
https://github.com/CivMC/Civ.git
synced 2026-07-18 00:20:44 +00:00
RAM caching is added by extending CitadelDao. When the plugin wants to query the database about a block, CitadelCachingDao transparantly loads all the reinforcement data in the same chunk as that block into the RAM, if it's not cached already. If changes are made to reinforcements on a cached chunk, those changes are consolidated in ram so there'll only be hd read/write when chunks are loaded/unloaded from the RAM cache. When new chunks are loaded into RAM, all chunks older than an age given in the config are released (and therefore flushed). There's a hard limit to the amount of chunks that can be held in RAM (to make resource-wasting griefing impossible) and when that limit is met, the entire cache is bypassed (to prevent thrashing). Right now this is completely untested, I haven't set up MySQL yet. Also, the craftbukkit library is now local and included relatively for ease of development.
3 lines
25 B
Plaintext
3 lines
25 B
Plaintext
Manifest-Version: 1.0
|
|
|