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

Ambiguous documentation around JSON encoding and names

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: doc
    • Labels:
      None

      Description

      otherwise it is encoded as a JSON object with one name/value pair whose name is the type's name and whose value is the recursively encoded value. For Avro's named types (record, fixed or enum) the user-specified name is used, for other types the type name is used.

      This quote from the documentation (source) leaves me with some questions about which names are allowed to be used in the encoded JSON.

      For example -

      • If we are decoding a union value in JSON using its type name as a tag, do we need to use the type's fullname (some.namespace.Foo), or can we use the unqualified name, Foo?
      • Does the answer change if Foo does not have an explicit namespace in the schema?
      • What should happen if the union's schema includes two types that differ only in namespace (namespace1.Foo vs. namespace2.Foo )?¬†
      • Are there¬†different rules for the null namespace?

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              imalsogreg Greg Hale
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated: