Class AbstractMain


  • public abstract class AbstractMain
    extends Object
    Abstract parent class of the main class of a QoS prototype. The class includes static, i.e., not generator or model dependent, code like command line reading, taking measurements or setting up prototyped resources.
    • Field Detail

      • LOGGER

        protected static final org.apache.log4j.Logger LOGGER
        Root LOGGER of the whole application. Changing its configuration impacts all log output.
      • threads

        protected List<Thread> threads
        Threads used to simulate users.
    • Constructor Detail

      • AbstractMain

        public AbstractMain()
    • Method Detail

      • run

        protected void run​(String[] args)
        Main method to run the generated prototype. It implements the main workflow, i.e., parsing cmd line, setting up resources, datastores, RMI registry, etc.
        Parameters:
        args - Command line arguments given for the prototype according to Apache CLI's configuration
      • startMeasurements

        protected void startMeasurements()
      • initAllocationStorage

        protected abstract void initAllocationStorage()
      • setupResources

        protected abstract void setupResources()
        Setup of resource
      • initialiseSystems

        protected abstract void initialiseSystems()
        Starts all system elements by calling their main methods.
      • getSystems

        protected abstract String[][] getSystems()
        Returns an array of systems (class + name tuple).
        Returns:
        [0]: class, [1]: name of each system element in this model
      • initialiseThreads

        protected abstract void initialiseThreads​(de.uka.ipd.sdq.sensorframework.entities.Experiment exp,
                                                  de.uka.ipd.sdq.sensorframework.entities.ExperimentRun expRun)
        Initialise threads and perform warmup, if requested.
        Parameters:
        exp -
        expRun -
      • getAssemblyContextFromArguments

        public static String getAssemblyContextFromArguments​(String[] args)
        Returns an assembly context from an argument string array.
        Parameters:
        args -
        Returns: