[
https://issues.apache.org/jira/browse/AVRO-1022?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Doug Cutting updated AVRO-1022:
-------------------------------
Attachment: AVRO-1022.patch
I guess I'm okay leaving the spec alone. But I question the wisdom of making
implementations less tolerant of non-ASCII or other errors in names. The Java
feature that disables validation was added because there are schemas and data
out there that do not conform to the spec but which Java should still be able
to process. Your patch here fails unit tests that depend on non-ASCII in names
and is an incompatible change for users who do.
For interoperability we might make Java more tolerant of schemas with invalid
names rather than less. For example, here's a patch that permits any name, but
prints warnings for names that don't conform to the spec. It also modifies the
compiler to escape characters that are not valid in Java identifiers. (This
isn't quite ready to commit, since it comments out some tests of things that
used to be parser errors but now we should test that they produce warnings.)
Maybe warnings aren't right. Maybe we should warn when validation is disabled
and throw exceptions when validation is enabled then enable folks to disable
validation in tools.
Such changes would permit us to generate code and read data regardless of
whether the implementation that created the schema and data validated names
correctly.
> Error in validate name
> ----------------------
>
> Key: AVRO-1022
> URL: https://issues.apache.org/jira/browse/AVRO-1022
> Project: Avro
> Issue Type: Bug
> Components: java
> Reporter: Raymie Stata
> Priority: Minor
> Attachments: AVRO-1022.patch, AVRO-1022.patch
>
>
> Fix schema.validateName to allow only ASCII letters, not Unicode letters.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira