Description
With code changes in https://github.com/apache/spark/pull/21847 , Spark can write out data as per user provided output schema.
To make it more robust and user friendly, we should validate the Avro schema before tasks launched.
Also we should support output logical decimal type as BYTES (By default we output as FIXED)