Dropped Memory class.

This commit is contained in:
MobiusDev
2018-09-23 11:46:00 +00:00
parent 9f44337989
commit 5f3fb62fd7
3 changed files with 4 additions and 44 deletions

View File

@@ -36,7 +36,6 @@ import com.l2jmobius.commons.mmocore.NetcoreConfig;
import com.l2jmobius.commons.mmocore.SelectorConfig;
import com.l2jmobius.commons.mmocore.SelectorThread;
import com.l2jmobius.commons.util.IPv4Filter;
import com.l2jmobius.commons.util.Memory;
import com.l2jmobius.commons.util.Util;
import com.l2jmobius.gameserver.cache.CrestCache;
import com.l2jmobius.gameserver.cache.HtmCache;
@@ -596,8 +595,8 @@ public class GameServer
Util.printSection("Info");
LOGGER.info("Maximum Numbers of Connected Players: " + Config.MAXIMUM_ONLINE_USERS);
LOGGER.info("GameServer Started, free memory " + Memory.getFreeMemory() + " Mb of " + Memory.getTotalMemory() + " Mb");
LOGGER.info("Used memory: " + Memory.getUsedMemory() + " MB");
LOGGER.info("GameServer Started, free memory " + (((Runtime.getRuntime().maxMemory() - Runtime.getRuntime().totalMemory()) + Runtime.getRuntime().freeMemory()) / 1048576) + " Mb of " + (Runtime.getRuntime().maxMemory() / 1048576) + " Mb");
LOGGER.info("Used memory: " + ((Runtime.getRuntime().totalMemory() - Runtime.getRuntime().freeMemory()) / 1048576) + " MB");
Util.printSection("Status");
System.gc();

View File

@@ -22,7 +22,6 @@ import java.util.concurrent.ScheduledFuture;
import java.util.logging.Logger;
import com.l2jmobius.commons.concurrent.ThreadPool;
import com.l2jmobius.commons.util.Memory;
import com.l2jmobius.commons.util.Util;
import com.l2jmobius.gameserver.model.L2World;
import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
@@ -69,8 +68,8 @@ public class ServerStatus
LOGGER.info("Active Players Online: " + ActivePlayers);
LOGGER.info("Offline Players Online: " + OfflinePlayers);
LOGGER.info("Threads: " + Thread.activeCount());
LOGGER.info("Free Memory: " + Memory.getFreeMemory() + " MB");
LOGGER.info("Used memory: " + Memory.getUsedMemory() + " MB");
LOGGER.info("Free Memory: " + (((Runtime.getRuntime().maxMemory() - Runtime.getRuntime().totalMemory()) + Runtime.getRuntime().freeMemory()) / 1048576) + " MB");
LOGGER.info("Used memory: " + ((Runtime.getRuntime().totalMemory() - Runtime.getRuntime().freeMemory()) / 1048576) + " MB");
Util.printSection("Server Status");
}
}