[jira] [Commented] (AVRO-2019) Improve documentation for logical type annotations in IDL
[ https://issues.apache.org/jira/browse/AVRO-2019?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17456659#comment-17456659 ] ASF subversion and git services commented on AVRO-2019: --- Commit 23c7802841f2ba997c6330f99a23704ea476b9de in avro's branch refs/heads/branch-1.11 from Oscar Westra van Holthe - Kind [ https://gitbox.apache.org/repos/asf?p=avro.git;h=23c7802 ] AVRO-2019: Improve documentation for logical type annotation (#1413) This is the 2017 patch from Andrew Rosca, documenting using @logicalType to allow arbitrary logical types in IDL. > Improve documentation for logical type annotations in IDL > - > > Key: AVRO-2019 > URL: https://issues.apache.org/jira/browse/AVRO-2019 > Project: Apache Avro > Issue Type: Improvement > Components: doc, logical types >Reporter: Andrew Rosca >Assignee: Andrew Rosca >Priority: Minor > Labels: pull-request-available > Fix For: 1.11.1 > > Attachments: AVRO-2019.patch > > Time Spent: 0.5h > Remaining Estimate: 0h > > The IDL documentation lacks information for how annotations can be specified > for logical types, like in the following example: > {code} > protocol test { > record test { > @logicalType("timestamp-millis") > long time; > } > } > {code} -- This message was sent by Atlassian Jira (v8.20.1#820001)
[jira] [Commented] (AVRO-2019) Improve documentation for logical type annotations in IDL
[ https://issues.apache.org/jira/browse/AVRO-2019?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17456658#comment-17456658 ] ASF subversion and git services commented on AVRO-2019: --- Commit d206242f3f8438421122accb87898a28eda1ea75 in avro's branch refs/heads/master from Oscar Westra van Holthe - Kind [ https://gitbox.apache.org/repos/asf?p=avro.git;h=d206242 ] AVRO-2019: Improve documentation for logical type annotation (#1413) This is the 2017 patch from Andrew Rosca, documenting using @logicalType to allow arbitrary logical types in IDL. > Improve documentation for logical type annotations in IDL > - > > Key: AVRO-2019 > URL: https://issues.apache.org/jira/browse/AVRO-2019 > Project: Apache Avro > Issue Type: Improvement > Components: doc, logical types >Reporter: Andrew Rosca >Assignee: Andrew Rosca >Priority: Minor > Labels: pull-request-available > Fix For: 1.11.1 > > Attachments: AVRO-2019.patch > > Time Spent: 0.5h > Remaining Estimate: 0h > > The IDL documentation lacks information for how annotations can be specified > for logical types, like in the following example: > {code} > protocol test { > record test { > @logicalType("timestamp-millis") > long time; > } > } > {code} -- This message was sent by Atlassian Jira (v8.20.1#820001)
[jira] [Commented] (AVRO-2019) Improve documentation for logical type annotations in IDL
[ https://issues.apache.org/jira/browse/AVRO-2019?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16168107#comment-16168107 ] Bridger Howell commented on AVRO-2019: -- Clarification on my previous comment: I do think this documentation update is a good idea; I was just trying to say that IDL logical types don't necessarily need to be treated internally as a feature separate from the generic metadata facility of IDL annotations. In order to break {{@logicalType}} annotations in IDL you'd probably either be changing the avro spec for logical types, or changing the way that annotations in IDL are processed, either of which is a breaking change already. On the other hand, if you try to retain the way {{@logicalType}} maps to a logical type separately from the way annotations are mapped, that could in many cases make IDL annotations harder to understand by complicating the mechanism. > Improve documentation for logical type annotations in IDL > - > > Key: AVRO-2019 > URL: https://issues.apache.org/jira/browse/AVRO-2019 > Project: Avro > Issue Type: Improvement > Components: doc, logical types >Reporter: Andrew Rosca >Assignee: Andrew Rosca >Priority: Minor > Attachments: AVRO-2019.patch > > > The IDL documentation lacks information for how annotations can be specified > for logical types, like in the following example: > {code} > protocol test { > record test { > @logicalType("timestamp-millis") > long time; > } > } > {code} -- This message was sent by Atlassian JIRA (v6.4.14#64029)
[jira] [Commented] (AVRO-2019) Improve documentation for logical type annotations in IDL
[ https://issues.apache.org/jira/browse/AVRO-2019?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16167884#comment-16167884 ] Sean Busbey commented on AVRO-2019: --- it looks like the timestamp related logical types are only in 1.8+. Folks have any preference between getting them added back into the 1.7 line vs updating this doc to use decimal (which is the only logical type defined in 1.7 AFAICT) > Improve documentation for logical type annotations in IDL > - > > Key: AVRO-2019 > URL: https://issues.apache.org/jira/browse/AVRO-2019 > Project: Avro > Issue Type: Improvement > Components: doc, logical types >Reporter: Andrew Rosca >Assignee: Andrew Rosca >Priority: Minor > Attachments: AVRO-2019.patch > > > The IDL documentation lacks information for how annotations can be specified > for logical types, like in the following example: > {code} > protocol test { > record test { > @logicalType("timestamp-millis") > long time; > } > } > {code} -- This message was sent by Atlassian JIRA (v6.4.14#64029)
[jira] [Commented] (AVRO-2019) Improve documentation for logical type annotations in IDL
[ https://issues.apache.org/jira/browse/AVRO-2019?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16167839#comment-16167839 ] Sean Busbey commented on AVRO-2019: --- Given the docs on logical types elsewhere, I think it's worth calling out this particular use of annotations in IDL. Folks who rely on IDL to use Avro shouldn't have to know the implementation details of how logical types are implemented via properties so that they can reason out how to use them in IDL. > Improve documentation for logical type annotations in IDL > - > > Key: AVRO-2019 > URL: https://issues.apache.org/jira/browse/AVRO-2019 > Project: Avro > Issue Type: Improvement > Components: doc, logical types >Reporter: Andrew Rosca >Priority: Minor > Attachments: AVRO-2019.patch > > > The IDL documentation lacks information for how annotations can be specified > for logical types, like in the following example: > {code} > protocol test { > record test { > @logicalType("timestamp-millis") > long time; > } > } > {code} -- This message was sent by Atlassian JIRA (v6.4.14#64029)
[jira] [Commented] (AVRO-2019) Improve documentation for logical type annotations in IDL
[ https://issues.apache.org/jira/browse/AVRO-2019?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16159986#comment-16159986 ] Bridger Howell commented on AVRO-2019: -- Isn't the way {{logicalType}} decorators work on types in IDL just a natural consequence of how IDL treats _any_ decorator on a type as a JSON property for that type, combined with the meaning of that field in the spec? I think this intent is expressed clearly enough in the IDL documentation "Annotation Ordering and Namespaces" (perhaps this section title is a bit too specific): {quote} Java-style annotations may be used to add additional properties to types and fields throughout Avro IDL. {quote} (Some details on specific properties/annotations) {quote} Some annotations like those listed above are handled specially. All other annotations are added as properties to the protocol, message, schema or field. {quote} I don't think I found a great generic/shared test of this, but there are at least a few spots where the the set of tests ran by {{org.apache.avro.compiler.idl.TestIdl}} show off this kind of behavior. For the IDL input {{simple.avdl}}, I see a case where the type of a field declared like: {{@foo("bar") MD5 hash = "";}} has the property {{"foo": "bar"}}. > Improve documentation for logical type annotations in IDL > - > > Key: AVRO-2019 > URL: https://issues.apache.org/jira/browse/AVRO-2019 > Project: Avro > Issue Type: Improvement > Components: doc, logical types >Reporter: Andrew Rosca >Priority: Minor > Attachments: AVRO-2019.patch > > > The IDL documentation lacks information for how annotations can be specified > for logical types, like in the following example: > {code} > protocol test { > record test { > @logicalType("timestamp-millis") > long time; > } > } > {code} -- This message was sent by Atlassian JIRA (v6.4.14#64029)
[jira] [Commented] (AVRO-2019) Improve documentation for logical type annotations in IDL
[ https://issues.apache.org/jira/browse/AVRO-2019?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=16053733#comment-16053733 ] Nandor Kollar commented on AVRO-2019: - Indeed, looks like this is missing from the documentation. Is this covered with tests too? I was looking for a relevant test case, but couldn't find any. [~arosca] do you know any relevant test case for this feature? > Improve documentation for logical type annotations in IDL > - > > Key: AVRO-2019 > URL: https://issues.apache.org/jira/browse/AVRO-2019 > Project: Avro > Issue Type: Improvement > Components: doc, logical types >Reporter: Andrew Rosca >Priority: Minor > Attachments: AVRO-2019.patch > > > The IDL documentation lacks information for how annotations can be specified > for logical types, like in the following example: > {code} > protocol test { > record test { > @logicalType("timestamp-millis") > long time; > } > } > {code} -- This message was sent by Atlassian JIRA (v6.4.14#64029)