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

Reflection-based schema not loading types

VotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Critical
    • Resolution: Cannot Reproduce
    • 1.9.1
    • None
    • java
    • None

    Description

      Avro reflection is unable to generate a schema for the following definition:

       
      public class Definition {
          public Map<String, Type>
      }
      
      public enum Type {
        A,
        B,
        C
      }
      
      // Test code
      Schema schema = ReflectData.get().getSchema(Definition.class)
      

      Fails with:
      Undefined name: "FieldType"
      org.apache.avro.SchemaParseException: Undefined name: "Type"

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            anhldbk Andy Le
            pcless Pedro Cardoso Silva
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment