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

Blocking for value output (with API change)

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 1.0.0
    • java
    • None

    Description

      The Avro specification has provisions for decomposing very large arrays and maps into "blocks." These provisions allow for streaming implementations that would allow one to, for example, write the contents of a file out as an Avro array w/out knowing in advance how many records are in the file.

      The current Java implementation of Avro does support this provision. My colleague Thiru will be attaching a patch which implements blocking. It turns out that the buffering required to do blocking is non-trivial, so it seem beneficial to include a standard implementation of blocking as part of the reference Avro implementation.

      This is an early version of the code. We are still working on testing and performance tuning. But we wanted early feedback.

      This patch also includes a new set of classes called ValueInput and ValueOutput, which are meant to replace ValueReader and ValueWriter. These classes have largely the same API as ValueReader/Writer, but they include a few more methods to "bracket" items that appear inside of arrays and maps. Shortly, we'll be posting a separate patch which implements further subclasses of ValueInput/Output that do "validation" of input and output against a schema (and also do automatic schema resolution for readers).

      We're implementing these classes separate from ValueInput/Output to allow you to kick our tires w/out causing too much disruption to your source trees. Let's validate the basic idea behind these patches first, and then determine the details of integrating them into the rest of Avro.

      Attachments

        1. AVRO-25.sh
          0.1 kB
          Thiruvalluvan M. G.
        2. AVRO-25.patch
          95 kB
          Thiruvalluvan M. G.
        3. AVRO-25.patch
          97 kB
          Thiruvalluvan M. G.
        4. AVRO-25.patch
          121 kB
          Thiruvalluvan M. G.
        5. AVRO-25.patch
          107 kB
          Thiruvalluvan M. G.
        6. AVRO-25.patch
          105 kB
          Thiruvalluvan M. G.
        7. AVRO-25.patch
          65 kB
          Thiruvalluvan M. G.

        Activity

          People

            thiru_mg Thiruvalluvan M. G.
            raymie Raymie Stata
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: