package simulator.stats; import java.io.IOException; import java.io.PrintStream; import java.util.List; import java.util.Map; import schedframe.scheduling.JobInterface; import simulator.AbstractGridBroker; import simulator.GenericUser; import eduni.simjava.Sim_stat; import gridsim.gssim.ResourceUnitsManagerImpl; import gridsim.gssim.resource.AbstractComputingResource; /** * TODO * @author Stanislaw Szczepanowski & Slawomir Bak * */ public interface SimulationStatisticsOld { /** * the mean job waiting time statistics */ public static final String TASK_WAITING_TIME = "Task waiting time"; /** * the makespan of all tasks in this simulation */ public static final String MAKESPAN = "Makespan"; public static final String TASK_COMPLETION_TIME = "Task completion time"; public static final String DELAYED_TASKS = "Delayed tasks"; public static final String TASK_TARDINESS = "Task tardiness"; public static final String TASK_LATENESS = "Task lateness"; public static final String TASK_FLOW_TIME = "Task flow time"; /** * the mean job execution time statistics name */ public static final String TASK_EXECUTION_TIME = "Task execution time"; /** * the failed requests (unfinished tasks count) statistics name */ public static final String FAILED_REQUESTS = "Failed requests (tasks)"; public static String[] TASK_STATISTICS_NAMES = { MAKESPAN, DELAYED_TASKS, FAILED_REQUESTS, TASK_WAITING_TIME, TASK_COMPLETION_TIME, TASK_TARDINESS, TASK_LATENESS, TASK_FLOW_TIME, TASK_EXECUTION_TIME, }; /**/ /** * Stores the total load of all resources */ public static final String RESOURCES_TOTAL_LOAD = "Resources total load"; /** * Stores the total load of all resources */ public static final String RESOURCES_RESERVATION_LOAD = "Resources reservation load"; /** * Stores the mean resources queue length */ public static final String RESOURCES_QUEUE_LENGTH = "Resources queue length"; public static String[] RESOURCES_STATISTICS_NAMES = { RESOURCES_TOTAL_LOAD, RESOURCES_QUEUE_LENGTH, }; /* ******************************************************************* */ public void gatherStatistics(GenericUser users, AbstractGridBroker brokerInterface, AbstractComputingResource gridResources[]); /** * Prints the detailed data for every entity, task * @param out the print writer to write the data to */ public void printSimulationStatistics(PrintStream out) throws IOException; public void printTasksInformation(PrintStream out, boolean printHistory) throws IOException; public void printResourcesInformation(PrintStream out) throws IOException; public boolean saveGanntsDiagrams(String path, String filenamePrefix); public void addStats(String name, GSSAccumulator value); public GSSAccumulator getStats(String name); /** * @return true, if all tasks sent by the users were completely finished before returning them to users */ public boolean areAllTasksFinished(); /** * The number of generated tasks in simulation this object represents * @return the generatedTaskCount */ public int getGeneratedTaskCount(); public int getReceivedTaskCount(); public int getGeneratedJobCount(); public int getReceivedJobCount(); public List> getReceivedJobs(); public Map> getResourcesReservations(); public Map> getBrokersReservations(); public ResourceUnitsManagerImpl getResourcesCharacteristics(String resourceName); public Sim_stat getBrokerStats(); /** * Indicates, whether any user entity created in the simulation has encountered an error. An error can be: * received the same job twice. * @return true if any error occurred. */ public boolean isUsersError(); public void setGenPEdiagram(boolean arg); }