Hey there! Developer of Mythic Dungeons here. We received a report of memory leaks and upon poking around in a heap dump found RealisticSeasons keeping a world in memory by holding on to it after it was unloaded. (Seen in the below picture.)
Mythic Dungeons does everything it can to mitigate this kind of issue, but with dynamic worlds there's only so much we can do.
The simplest solution for this would be to add an event handler for WorldUnloadEvent that clears the unloaded world from the worlds tracked by your SpringBlockTicker. You could also regularly check if the world is being tracked by Bukkit still with a Bukkit.getWorld(worldName), or use a WeakReference instead of if you'd rather not an event handler or don't have a convenient way to regularly check if the world is active.
By the way, love the plugin, looks really well-made! Keep up the good work.
Hey there! Developer of Mythic Dungeons here. We received a report of memory leaks and upon poking around in a heap dump found RealisticSeasons keeping a world in memory by holding on to it after it was unloaded. (Seen in the below picture.)
Mythic Dungeons does everything it can to mitigate this kind of issue, but with dynamic worlds there's only so much we can do.
The simplest solution for this would be to add an event handler for WorldUnloadEvent that clears the unloaded world from the worlds tracked by your SpringBlockTicker. You could also regularly check if the world is being tracked by Bukkit still with a instead of if you'd rather not an event handler or don't have a convenient way to regularly check if the world is active.
Bukkit.getWorld(worldName)
, or use a WeakReferenceBy the way, love the plugin, looks really well-made! Keep up the good work.