Chunky (Bukkit)

Chunky (Bukkit)

20.6k Downloads

Question regarding Chunky internal operation

Frontear opened this issue ยท 1 comments

commented

Hi

Sorry I wasn't sure where to go with this. I'm currently tracking an issue of a memory leak within a large modpack and we've narrowed it down to chunk loading behavior. Thing is, I notice that with Chunky, the pregeneration does NOT cause this mem leak, while it does with another mod that loads chunks. Obviously this behavior seems rather odd to me, so I wanted to ask devs how Chunky pregen operates internally? How is it generating those chunks and what does it do with them after they are loaded.

commented

Hey thanks for the question. It's fine to ask here but generally quicker to respond on our Discord server (linked from the project page and here on the readme).

Chunky queues chunk loads to the server and puts a ticket on the chunk to ensure that it reaches full status while generating, and then removes the ticket once done. There generally shouldn't be any issues unless other mods are leaking memory or preventing chunks from unloading.

Keep in mind though, often people confuse memory leaks with high memory utilization, which is rather normal during pregen as a result of memory churn with the rapid loading and unloading of chunks to generate them. Make sure that this isn't the issue, if you are crashing maybe try either increasing or decreasing server memory allocation by a few GB if you are having issues. Sometimes that will fix it. If you are 100% certain that you do have a memory leak I would either try removing mods until it isn't an issue to narrow down the culprit or make a heap dump (if you need help evaluating this feel free to share it on Discord and I'd be happy to take a peek).