Enum Class TaskEventType

java.lang.Object
java.lang.Enum<TaskEventType>
org.cloudsimplus.traces.google.TaskEventType
All Implemented Interfaces:
Serializable, Comparable<TaskEventType>, Constable

public enum TaskEventType extends Enum<TaskEventType>
Defines the type of TaskEvent (a line) in the trace file that represents the state of the job. Each enum instance is a possible value for the TaskEventField.EVENT_TYPE field.
Since:
CloudSim Plus 4.0.0
Author:
Manoel Campos da Silva Filho
  • Nested Class Summary

    Nested classes/interfaces inherited from class java.lang.Enum

    Enum.EnumDesc<E extends Enum<E>>
  • Enum Constant Summary

    Enum Constants
    Enum Constant
    Description
    2: A task or job was de-scheduled because of a higher priority task or job, because the scheduler over-committed and the actual demand exceeded the machine capacity, because the machine on which it was running became unusable (e.g.
    3: A task or job was de-scheduled (or, in rare cases, ceased to be eligible for scheduling while it was pending) due to a task failure.
    4: A task or job completed normally.
    5: A task or job was cancelled by the user or a driver program or because another job or task on which this job was dependent died.
    6: A task or job was presumably terminated, but a record indicating its termination was missing from our source data.
    1: A job or task was scheduled on a machine (it may not start running immediately due to code-shipping time, etc).
    0: A task or job became eligible for scheduling.
    7: A task or job’s scheduling class, resource requirements, or constraints were updated while it was waiting to be scheduled.
    8: A task or job’s scheduling class, resource requirements, or constraints were updated while it was scheduled.
  • Method Summary

    Modifier and Type
    Method
    Description
    getValue(int ordinal)
    Gets an enum instance from its ordinal value.
    protected static TaskEventType
    Gets the enum value that represents the event type of the current trace line.
    protected abstract boolean
    Executes an operation with the Cloudlet according to the Event Type.
    Returns the enum constant of this class with the specified name.
    static TaskEventType[]
    Returns an array containing the constants of this enum class, in the order they are declared.

    Methods inherited from class java.lang.Object

    getClass, notify, notifyAll, wait, wait, wait
  • Enum Constant Details

    • SUBMIT

      public static final TaskEventType SUBMIT
      0: A task or job became eligible for scheduling.
    • SCHEDULE

      public static final TaskEventType SCHEDULE
      1: A job or task was scheduled on a machine (it may not start running immediately due to code-shipping time, etc). For jobs, this occurs the first time any task of the job is scheduled on a machine.
    • EVICT

      public static final TaskEventType EVICT
      2: A task or job was de-scheduled because of a higher priority task or job, because the scheduler over-committed and the actual demand exceeded the machine capacity, because the machine on which it was running became unusable (e.g. taken offline for repairs), or because a disk holding the task’s data was lost.
    • FAIL

      public static final TaskEventType FAIL
      3: A task or job was de-scheduled (or, in rare cases, ceased to be eligible for scheduling while it was pending) due to a task failure.
    • FINISH

      public static final TaskEventType FINISH
      4: A task or job completed normally.
    • KILL

      public static final TaskEventType KILL
      5: A task or job was cancelled by the user or a driver program or because another job or task on which this job was dependent died.
    • LOST

      public static final TaskEventType LOST
      6: A task or job was presumably terminated, but a record indicating its termination was missing from our source data.
    • UPDATE_PENDING

      public static final TaskEventType UPDATE_PENDING
      7: A task or job’s scheduling class, resource requirements, or constraints were updated while it was waiting to be scheduled.
    • UPDATE_RUNNING

      public static final TaskEventType UPDATE_RUNNING
      8: A task or job’s scheduling class, resource requirements, or constraints were updated while it was scheduled.
  • Method Details

    • values

      public static TaskEventType[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static TaskEventType valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • getValue

      public static TaskEventType getValue(int ordinal)
      Gets an enum instance from its ordinal value.
      Parameters:
      ordinal - the ordinal value to get the enum instance from
      Returns:
      the enum instance
    • process

      protected abstract boolean process(GoogleTaskEventsTraceReader reader)
      Executes an operation with the Cloudlet according to the Event Type. Each enum value must implement this method to include its own processing logic.
      Returns:
      true if trace line for the event type was processed, false otherwise
    • of

      protected static TaskEventType of(GoogleTaskEventsTraceReader reader)
      Gets the enum value that represents the event type of the current trace line.
      Returns:
      the MachineEventType value