Class HL7v2IO.ListHL7v2Messages

  • All Implemented Interfaces:
    java.io.Serializable, org.apache.beam.sdk.transforms.display.HasDisplayData
    Enclosing class:
    HL7v2IO

    public static class HL7v2IO.ListHL7v2Messages
    extends org.apache.beam.sdk.transforms.PTransform<org.apache.beam.sdk.values.PBegin,​org.apache.beam.sdk.values.PCollection<HL7v2Message>>
    List HL7v2 messages in HL7v2 Stores with optional filter.

    This transform is optimized for splitting of message.list calls for large batches of historical data and assumes rather continuous stream of sendTimes.

    Note on Benchmarking: The default initial splitting on day will make more queries than necessary when used with very small data sets (or very sparse data sets in the sendTime dimension). If you are looking to get an accurate benchmark be sure to use sufficient volume of data with messages that span sendTimes over a realistic time range (days)

    Implementation includes overhead for:

    1. two api calls to determine the min/max sendTime of the HL7v2 store at invocation time.
    2. initial splitting into non-overlapping time ranges (default daily) to achieve parallelization in separate messages.list calls.
    If your use case doesn't lend itself to daily splitting, you can can control initial splitting with withInitialSplitDuration(Duration)
    See Also:
    Serialized Form
    • Field Summary

      • Fields inherited from class org.apache.beam.sdk.transforms.PTransform

        name, resourceHints
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      org.apache.beam.sdk.values.PCollection<HL7v2Message> expand​(org.apache.beam.sdk.values.PBegin input)  
      HL7v2IO.ListHL7v2Messages withInitialSplitDuration​(org.joda.time.Duration initialSplitDuration)  
      • Methods inherited from class org.apache.beam.sdk.transforms.PTransform

        compose, compose, getAdditionalInputs, getDefaultOutputCoder, getDefaultOutputCoder, getDefaultOutputCoder, getKindString, getName, getResourceHints, populateDisplayData, setResourceHints, toString, validate, validate
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Method Detail

      • withInitialSplitDuration

        public HL7v2IO.ListHL7v2Messages withInitialSplitDuration​(org.joda.time.Duration initialSplitDuration)
      • expand

        public org.apache.beam.sdk.values.PCollection<HL7v2Message> expand​(org.apache.beam.sdk.values.PBegin input)
        Specified by:
        expand in class org.apache.beam.sdk.transforms.PTransform<org.apache.beam.sdk.values.PBegin,​org.apache.beam.sdk.values.PCollection<HL7v2Message>>