Record Class SampleDataDescriptor

java.lang.Object
java.lang.Record
ai.pipestream.module.pipelineprobe.sampledata.SampleDataDescriptor
Record Components:
artifactId - Maven artifactId / repo name, e.g. chunker-input-court
stage - pipeline step this dataset is the INPUT to, e.g. chunker
producedByModule - module that produced these docs (the previous step), e.g. echo
consumedByModule - module that consumes these docs (what this dataset stresses)
captureNode - engine graph_address_id the docs were captured at
crawlId - crawl run id the dataset was harvested from
sourceDocCount - number of source docs in the dataset (the expected per-step count)
format - human note on the on-disk format
path - classpath path template, e.g. fixtures/court/chunker/doc_NNNN.pb.gz
pairing - note on cross-step doc_NNNN pairing

public record SampleDataDescriptor(String artifactId, String stage, String producedByModule, String consumedByModule, String captureNode, String crawlId, int sourceDocCount, String format, String path, String pairing) extends Record
One sample-data fixture jar's self-description, read from its META-INF/pipestream-sample-data.json resource.

Each <step>-input-court jar (and any future fixture jar following the same convention) ships exactly one of these — a passive, dependency-free descriptor. The SampleDataRegistry discovers them on the classpath at startup so the harness knows, per dataset: which step it feeds, how many docs to expect, which crawl produced it, and where the .pb.gz files live.

Unknown fields are ignored so new descriptor keys don't break older consumers.

  • Constructor Details

    • SampleDataDescriptor

      public SampleDataDescriptor(String artifactId, String stage, String producedByModule, String consumedByModule, String captureNode, String crawlId, int sourceDocCount, String format, String path, String pairing)
      Creates an instance of a SampleDataDescriptor record class.
      Parameters:
      artifactId - the value for the artifactId record component
      stage - the value for the stage record component
      producedByModule - the value for the producedByModule record component
      consumedByModule - the value for the consumedByModule record component
      captureNode - the value for the captureNode record component
      crawlId - the value for the crawlId record component
      sourceDocCount - the value for the sourceDocCount record component
      format - the value for the format record component
      path - the value for the path record component
      pairing - the value for the pairing record component
  • Method Details

    • resourceDir

      public String resourceDir()
      Classpath directory holding the per-doc files (derived from path).
      Returns:
      the directory portion of path (everything before the last '/'), or the empty string if path is null or contains no slash
    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with the compare method from their corresponding wrapper classes.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • artifactId

      public String artifactId()
      Returns the value of the artifactId record component.
      Returns:
      the value of the artifactId record component
    • stage

      public String stage()
      Returns the value of the stage record component.
      Returns:
      the value of the stage record component
    • producedByModule

      public String producedByModule()
      Returns the value of the producedByModule record component.
      Returns:
      the value of the producedByModule record component
    • consumedByModule

      public String consumedByModule()
      Returns the value of the consumedByModule record component.
      Returns:
      the value of the consumedByModule record component
    • captureNode

      public String captureNode()
      Returns the value of the captureNode record component.
      Returns:
      the value of the captureNode record component
    • crawlId

      public String crawlId()
      Returns the value of the crawlId record component.
      Returns:
      the value of the crawlId record component
    • sourceDocCount

      public int sourceDocCount()
      Returns the value of the sourceDocCount record component.
      Returns:
      the value of the sourceDocCount record component
    • format

      public String format()
      Returns the value of the format record component.
      Returns:
      the value of the format record component
    • path

      public String path()
      Returns the value of the path record component.
      Returns:
      the value of the path record component
    • pairing

      public String pairing()
      Returns the value of the pairing record component.
      Returns:
      the value of the pairing record component