TomBruns opened a new pull request, #2751: URL: https://github.com/apache/avro/pull/2751
[AVRO-2825](https://issues.apache.org/jira/browse/AVRO-2825?jql=text%20~%20%22csharp%20logical%22) ## What is the purpose of the change - This pull request resolves an outstanding issue with the csharp implementation behavior that is **not consistent** with the AVRO spec and the java behavior. - Per the AVRO Spec: - *Language implementations must ignore unknown logical types when reading, and should use the underlying Avro type* - The current csharp implementation throws an exception for unrecognized Logical Types. **NOTE: This PR WILL change the behavior of the current nuget package. It corrects it to align with the AVRO spec.** ### This is a new version of PR #2741 incorporating all feedback from KalleOlaviNiemitalo Avoid swallowing any exceptions thrown for other reasons. Allow applications to parse a schema and read the name of the logical type from LogicalSchema.LogicalTypeName (or even LogicalType.Name) regardless of whether the library recognizes it. Allow applications to parse a schema and serialize it back to JSON without losing the unrecognized logical types here: LogicalSchema.LogicalType could then be null, or perhaps an instance of a new NotSupportedLogicalType class that would pass everything through without conversion. (I created a new type: UnknownLogicalType) ## Verifying this change This change is already covered by existing tests: - test > AvroGen > AvroGenSchemaTests.cs > NotSupportedSchema - corrected expected result of Test - test > Schema > SchemaTests.cs > TestUnknownLogical - corrected expected result of Test This change added tests and can be verified as follows: - test > Util > LogicalTypeTests.cs > TestUnknownLogicalType - added more complex test to confirm underlying AVRO base type is used. ## Documentation - Does this pull request introduce a new feature? (no) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: dev-unsubscr...@avro.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org