Interface Annotation

All Superinterfaces:
NBLabeledElement
All Known Implementing Classes:
MutableAnnotation

public interface Annotation extends NBLabeledElement
This is a general purpose representation of an event that describes a significant workflow detail to users running tests. It can be an event that describes an instant, or it can describe an interval in time (being associated with the interval of time between two canonical events.) This view of an annotation event captures the semantics of what any reportable annotation should look like from the perspective of NoSQLBench. It is up to the downstream consumers to map these to concrete fields or identifiers as appropriate.
  • Method Details

    • getStartMillis

      long getStartMillis()
      If this is the same as getEndMillis(), then the annotation is for an instant in time.
      Returns:
      The beginning of the interval of time that the annotation describes
    • getEndMillis

      long getEndMillis()
      If this is the same as getStartMillis(), then the annotation is for an instant in time.
      Returns:
      The end of the interval of time that the annotation describes
    • getLayer

      Layer getLayer()
      Annotations must be associated with a processing layer in NoSQLBench. For more details on layers, see Layer
      Returns:
      the Layer to which the annotations applies
    • getLabels

      NBLabels getLabels()
      The labels which identify what this annotation pertains to. The following labels should be provided for every annotation, when available:
      • appname: "nosqlbench"
      • alias: The name of the activity alias, if available
      • workload: The name of the workload file, if named scenarios are used
      • scenario: The name of the named scenario, if named scenarios are used
      • step: The name of the named scenario step, if named scenario are used
      • usermode: "named_scenario" or "adhoc_activity"
      Specified by:
      getLabels in interface NBLabeledElement
      Returns:
      The labels map
    • applyLabelFunction

      void applyLabelFunction(Function<NBLabels,NBLabels> labelfunc)
    • getDetails

      Map<String,String> getDetails()
      The details are an ordered map of all the content that you would want the user to see.
      Returns:
      The details map
    • newBuilder

    • getTemporal

      Temporal getTemporal()
      This should return Temporal.interval if the span of time is not an instant, and Temporal.instant, otherwise.
    • asJson

      String asJson()
    • getDurationMillis

      default long getDurationMillis()