Avro
  1. Avro
  2. AVRO-304

There should be a way to do schema resolution with SpecificDatumReader

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Major Major
    • Resolution: Invalid
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: java
    • Labels:
      None

      Description

      Presently one could do schema resolution (where the schema of the Avro data stream is different from the Schema desired by the reader) only with GenericDatumReader. A similar facility is needed for SpecificDatumReader as well.

      1. AVRO-304.patch
        1 kB
        Thiruvalluvan M. G.

        Activity

        Thiruvalluvan M. G. created issue -
        Hide
        Thiruvalluvan M. G. added a comment -

        This patch addresses this problem.

        Show
        Thiruvalluvan M. G. added a comment - This patch addresses this problem.
        Thiruvalluvan M. G. made changes -
        Field Original Value New Value
        Attachment AVRO-304.patch [ 12429852 ]
        Thiruvalluvan M. G. made changes -
        Attachment AVRO-304.patch [ 12429867 ]
        Thiruvalluvan M. G. made changes -
        Attachment AVRO-304.patch [ 12429852 ]
        Hide
        Doug Cutting added a comment -

        This is already possible. One creates the SpecificDatumReader using the expected class. The user of the DatumReader (e.g., DataFileReader) can then call setSchema() with the actual schema.

        Show
        Doug Cutting added a comment - This is already possible. One creates the SpecificDatumReader using the expected class. The user of the DatumReader (e.g., DataFileReader) can then call setSchema() with the actual schema.
        Hide
        Thiruvalluvan M. G. added a comment -

        Doug's solution works. Thanks Doug.

        Show
        Thiruvalluvan M. G. added a comment - Doug's solution works. Thanks Doug.
        Thiruvalluvan M. G. made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Invalid [ 6 ]
        Doug Cutting made changes -
        Status Resolved [ 5 ] Closed [ 6 ]
        Transition Time In Source Status Execution Times Last Executer Last Execution Date
        Open Open Resolved Resolved
        2d 20h 13m 1 Thiruvalluvan M. G. 13/Jan/10 13:20
        Resolved Resolved Closed Closed
        47d 8h 26m 1 Doug Cutting 01/Mar/10 21:47

          People

          • Assignee:
            Thiruvalluvan M. G.
            Reporter:
            Thiruvalluvan M. G.
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development