Uploaded image for project: 'Apache Avro'
  1. Apache Avro
  2. AVRO-1238

Avro-C better end of file detection

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • None
    • c
    • None

    Description

      Currently in the C library, avro_file_reader_read_value will error out when it hits the end of a file.

      I propose we make it detect when it has hit the end of file, and return -1.
      This means that we can differentiate between errors in opening the next block versus actually having finished the file.

      I have attached the proposed changes.

      Attachments

        1. avro-1238-truncated.avro
          0.1 kB
          Douglas Creager
        2. avro-1238-good.avro
          0.1 kB
          Douglas Creager
        3. 0001-Test-case-for-AVRO-1238.patch
          5 kB
          Douglas Creager
        4. 0001-Sane-EOF-checking.patch
          5 kB
          Michael Cooper
        5. 0001-AVRO-1238.-C-Check-for-EOF-when-reading-from-Avro-fi.patch
          7 kB
          Douglas Creager

        Activity

          People

            Unassigned Unassigned
            mic159 Michael Cooper
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: