Uploaded image for project: 'Apache Hudi'
  1. Apache Hudi
  2. HUDI-6164

Create new version for RawTripTestPayload to avoid misuse

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Open
    • Major
    • Resolution: Unresolved
    • None
    • None
    • None
    • None

    Description

      org.apache.hudi.common.testutils.HoodieTestDataGenerator has been omitting ordering value when creating RawTripTestPayload, as a result, the records generated are not usable for merging. This involves these 2 constructors

      org.apache.hudi.common.testutils.RawTripTestPayload#RawTripTestPayload(org.apache.hudi.common.util.Option<java.lang.String>, java.lang.String, java.lang.String, java.lang.String, java.lang.Boolean, java.lang.Comparable)
      org.apache.hudi.common.testutils.RawTripTestPayload#RawTripTestPayload(java.lang.String, java.lang.String, java.lang.String, java.lang.String)
      

      On the other hand, there are test cases construct RawTripTestPayload with json data directly and fix the partition field as `time` using this constructor

      org.apache.hudi.common.testutils.RawTripTestPayload#RawTripTestPayload(java.lang.String)
      

      These are contradicting usage of this class. We should create another payload class for the 2nd use case (fixed simple schema). And make RawTripTestPayload support setting ordering value with HoodieTestDataGenerator.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              xushiyan Shiyan Xu
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated: