Class EnduranceConfig

java.lang.Object
org.acemq.workloads.endurance.EnduranceConfig

public final class EnduranceConfig extends Object
What an endurance run is asked to do: the soak's numbers, the clients to watch and how each one is started, the allowances a leak has to cross, and the upstream defects allowed within a measured ceiling.

Every default is what scripts/soak.sh used, so a run with no file and no flags is the soak the release preflight has always read. A YAML file overrides any of it; flags override the file.

  • Field Details

    • LANGUAGES

      public static final List<String> LANGUAGES
      The five standing loads the workspace has, in the order the soak always listed them.
    • workspace

      public String workspace
      The workspace the default launch commands, reports and pid files are relative to.
    • broker

      public String broker
      The AMQP endpoint every standing load publishes to.
    • management

      public String management
      The management API the fault and the connection counts go through.
    • managementUser

      public String managementUser
      Management credentials; taken from the broker URL when not given.
    • managementPassword

      public String managementPassword
    • cycles

      public int cycles
    • cycleSeconds

      public int cycleSeconds
    • warmupSeconds

      public int warmupSeconds
    • sampleSeconds

      public int sampleSeconds
    • cooldownSeconds

      public int cooldownSeconds
      After the last cycle: a client still mid-recovery holds two of some things.
    • readings

      public int readings
      Readings taken for the baseline and again at the end; the verdict takes the median.
    • readingGapSeconds

      public int readingGapSeconds
    • startupSeconds

      public int startupSeconds
      How long a load has to write its first sample before it counts as one that will not start. Builds run before the clock starts.
    • allowances

      public EnduranceConfig.Allowances allowances
    • reportDir

      public String reportDir
      Relative to the workspace unless absolute.
    • stateDir

      public String stateDir
      Pid files, sample files and raw readings; relative to the workspace unless absolute.
    • keep

      public boolean keep
      Leave the loads this run started running when it ends.
    • clients

      public List<String> clients
    • launch

      Per-client launch settings, laid over the defaults field by field.
    • knownUpstream

      public List<EnduranceConfig.KnownUpstream> knownUpstream
  • Constructor Details

    • EnduranceConfig

      public EnduranceConfig()
  • Method Details

    • read

      public static EnduranceConfig read(Path file)
      Parameters:
      file - an endurance YAML file, or null for the defaults
      Returns:
      the configuration
    • validate

      public void validate()
      Throws:
      ConfigException - if a number is out of range or a client has no way to start
    • launchFor

      public EnduranceConfig.Launch launchFor(String client)
      Returns:
      the launch for a client: the default, with whatever the file set laid over it