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

Python compatibility check fails if record with and without namespace are compared

    XMLWordPrintableJSON

Details

    Description

      Avro spec:

       To match, one of the following must hold:
      ...
        * both schemas are records with the same (unqualified) name

      Following records are compatible. The `ReaderWriterCompatibilityChecker` reports name mismatch and an incompatibility. Similar test case with Java implementation passes.

      WITHOUT_NAMESPACE_RECORD = parse(
          json.dumps(
              {
                  "type": SchemaType.RECORD,
                  "name": "Record1",
                  "fields": [
                      {
                          "name": "f1",
                          "type": "int",
                      }
                  ],
              },
          )
      )
      WITH_NAMESPACE_RECORD = parse(
          json.dumps(
              {
                  "type": SchemaType.RECORD,
                  "name": "ns.Record1",
                  "fields": [
                      {
                          "name": "f1",
                          "type": "int",
                      }
                  ],
              },
          )
      )
       
      

      Attachments

        Issue Links

          Activity

            People

              jjaakola-aiven Jarkko Jaakola
              jjaakola-aiven Jarkko Jaakola
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 3h 50m
                  3h 50m