Download Apoli Stream Leak — Minecraft Mods — MetaMods

Apoli Stream Leak

Active

Downloads

0

Last update

2 weeks ago
Client

Apoli Stream Leak

Apoli Stream Leak is a coremod for Forge that aims to fix avoidable performance issues for Apoli (Forge).

Purpose

Apoli is a 3rd-party redistribution of a library that comes built-in with Origins (Forge) that modders can use without needing to depend on the rest of Origins. There are several instances within Apoli's code where Streams are created in methods that are called every tick on both the client and server. The creations of these Streams, along with their associated lambda allocations, have caused noticeable performance degradations, especially on servers with multiple players connected.

Apoli Stream Leak overwrites the usages of these Stream creations with traditional for-loops and other alternative implementations in order to avoid excess memory usage. The result is immediate.

Performance Difference

Here is a Spark profile of the Resurvival modpack which contains Apoli:
https://spark.lucko.me/Qa87epEMA8

Here is a Spark profile of the same instance now including Apoli Stream Leak:
https://spark.lucko.me/vQ1lXBRg7w

Within Spark's own mod tree, Apoli itself sees a 4% decrease in tick time when paired with Apoli Stream Leak. Other mods such as Mining Master, which use events that Apoli directly hooks into, also see a decrease of around 1% or greater.

Open to Other Solutions

Apoli Stream Leak was created due to the absense of a open-source/source-available repository for Apoli (Forge) (NOT to be confused with the original Apoli mod). I am personally open to contributing the changes I have made with this coremod to Apoli itself (preferably for the Forge version as that is my use case). You can find me at jonathing.me.

Project members
Jonathing

Jonathing