You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@avro.apache.org by "KalleOlaviNiemitalo (via GitHub)" <gi...@apache.org> on 2023/04/19 09:01:43 UTC

[GitHub] [avro] KalleOlaviNiemitalo commented on a diff in pull request #2192: AVRO-XXXX: Given array example in the documentation is incorrect

KalleOlaviNiemitalo commented on code in PR #2192:
URL: https://github.com/apache/avro/pull/2192#discussion_r1171040966


##########
doc/content/en/docs/++version++/Specification/_index.md:
##########
@@ -137,9 +137,9 @@ For example, an array of strings is declared with:
 ```json
 {
   "type": "array",
-  "items" : "string",
-  "default": []
-}
+  "items" : "string"
+},
+"default": []
 ```

Review Comment:
   This doesn't look right either. If there is a JSON property with name `"default"` and value `[]`, then the previous schema object `{ "type": array", "items": "string" }` should also be a value of a property, and the name of that property should be shown.
   
   I think it would be best to just delete `"default": []` from this example, and also from the example under "Maps". The "default" property is meaningful in fields and enum schemas but not in other schemas.



-- 
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: issues-unsubscribe@avro.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org