package mineplex.serverstatifier; public class ServerStatifier { private static StatusSnapshotRepository _statusSnapshotRepository = new StatusSnapshotRepository(); private static StatusHistoryRepository _statusHistoryRepository = new StatusHistoryRepository(); private static int count = 0; public static void main (String args[]) { _statusSnapshotRepository.initialize(); _statusHistoryRepository.initialize(); while (true) { _statusHistoryRepository.saveServerStats(_statusSnapshotRepository.retrieveGroupStatusData()); _statusHistoryRepository.saveBungeeStats(_statusSnapshotRepository.retrieveBungeeStatuses()); try { Thread.sleep(60000); } catch (InterruptedException e) { e.printStackTrace(); } count++; if (count % 5 == 0) System.out.println("5 Minute status update....still awesome."); } } }