Avro not available in spark2

I am unable to save the file using Avro.

[nirmalgaprialdevanesan@gw03 ~]$ spark2-shell --master yarn --num-executors 10 --executor-memory 3G --executor-cores 2 --packages com.databricks:spark-avro_2.10:2.0.1
SPARK_MAJOR_VERSION is set to 2, using Spark2

scala> import com.databricks.spark.avro._
import com.databricks.spark.avro._

scala> wordcountdf.write.avro("/user/nirmalgaprialdevanesan/solutions/solution05/wordcount")
:39: error: value avro is not a member of org.apache.spark.sql.DataFrameWriter[org.apache.spark.sql.Row]
wordcountdf.write.avro("/user/nirmalgaprialdevanesan/solutions/solution05/wordcount")

Hi @nirmal_gaprial,
you have to use different version of avro package (com.databricks:spark-avro_2.11:4.0.0).
please try to lauch spark2-shell with below code-

spark2-shell --master yarn --conf spark.ui.port=0 --num-executors 10 --executor-memory 3G --executor-cores 2 --packages com.databricks:spark-avro_2.11:4.0.0

thanks its working now, can you please resolve the save
scala> wordcountdf.save("/user/nirmalgaprialdevanesan/solutions/solution05/wordcount",“avro”)
:29: error: value save is not a member of org.apache.spark.sql.DataFrame
wordcountdf.save("/user/nirmalgaprialdevanesan/solutions/solution05/wordcount",“avro”)

i am unable to user save