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

Julian Hyde commented on CALCITE-1026:
--------------------------------------

Thanks for a nice (and unexpected) PR, [~Sergey Nuyanzin].

Do you think that we should indicate to users and developers that one of JSON 
or YAML is in some sense "preferred"? Or should we treat both equally? (I.e. 
write tests in both/either.)

Now you've split ModelTest, JsonModelTest and YamlModelTest are replicas of 
each other. What should be the relationship between those tests going forward? 
Is it required to add a test in one place or both places? The documentation on 
the tests should make it clear.

I saw clever code that determines whether an "inline:" model is JSON or YAML, 
but I didn't see documentation. At least 
https://calcite.apache.org/docs/adapter.html#jdbc-connect-string-parameters 
needs to be updated. (It doesn't look as if we've documented "inline:" anywhere 
in the online doc. Time to change that.)

If people are writing inline YAML models they will want to use line endings in 
their connect string. We should test that both windows and unix line endings 
both work.

> Model in YAML format
> --------------------
>
>                 Key: CALCITE-1026
>                 URL: https://issues.apache.org/jira/browse/CALCITE-1026
>             Project: Calcite
>          Issue Type: Bug
>            Reporter: Julian Hyde
>            Assignee: Julian Hyde
>            Priority: Major
>
> Models must currently be in JSON. YAML is more forgiving and flexible, so we 
> should support YAML as a format.
> Jackson (versions 2.5 and above) can read YAML files and produce the same 
> output as the corresponding JSON.
> As part of this change, we should add an example to 
> http://calcite.apache.org/docs/model.html.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to