[ 
https://issues.apache.org/jira/browse/AVRO-2742?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17039832#comment-17039832
 ] 

Ryan Skraba commented on AVRO-2742:
-----------------------------------

Good point about aliases – I'll add that to the other JIRA!

I'm pretty sure that being able to disable name validation is the "escape 
valve" for cases like this.  If we fix Avro to match the spec, it's going to 
break _someone_ who relied on it being buggy!

BTW, the AvroCalciteRest link looks really cool.  We run into the problem of 
having to store "db column names" with arbitrary rules as Avro fields all the 
time... it might be worthwhile thinking about mangling/demangling arbitrary as 
a feature.

> Schema.Parser.parse() does not validate namespace
> -------------------------------------------------
>
>                 Key: AVRO-2742
>                 URL: https://issues.apache.org/jira/browse/AVRO-2742
>             Project: Apache Avro
>          Issue Type: Bug
>          Components: java
>    Affects Versions: 1.9.2
>            Reporter: radai rosenblatt
>            Priority: Major
>
> [the spec|https://avro.apache.org/docs/current/spec.html#names] has the 
> following to say about names:
> {quote}The name portion of a fullname, record field names, and enum symbols 
> must: ... A namespace is a dot-separated sequence of such names.
> {quote}
> and yet the following schema parses just fine for me:
> {code:java}
> {
>   "type": "record",
>   "namespace": "this thing. has spaces.in it?!",
>   "name": "HasInvalidNamespace",
>   "fields": [
>     {
>       "name": "stringField",
>       "type": "string"
>     }
>   ]
> }
> {code}
> am I misunderstanding the spec? also, even if this is technically a legal 
> schema it will never survive code generation of specific record classes (at 
> least in java?)



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to