gengliangwang commented on code in PR #48043:
URL: https://github.com/apache/spark/pull/48043#discussion_r1762241180
##########
docs/sql-data-sources-avro.md:
##########
@@ -628,3 +635,41 @@ You can also specify the whole output Avro schema with the
option `avroSchema`,
<td>decimal</td>
</tr>
</table>
+
+## Handling circular references of Avro fields
+In Avro, a circular reference occurs when the type of a field is defined in
one of the parent records. This can cause issues when parsing the data, as it
can result in infinite loops or other unexpected behavior.
+To read Avro data with schema that has circular reference, users can use the
`recursiveFieldMaxDepth` option to specify the maximum number of levels of
recursion to allow when parsing the schema. By default, `spark-avro` will not
permit recursive fields by setting `recursiveFieldMaxDepth` to -1. However, you
can set this option to 1 to 15 if needed.
Review Comment:
Replace `spark-avro` to `Spark Avro data source` ?
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]