Hi,
I am trying to use this library to convert json-schema to Spark Structs. Using scala version 2.12.14
import org.zalando.spark.jsonschema.SchemaConverter
import scala.io.Source
val schemaUrl = "https://raw.githubusercontent.com/CMSgov/price-transparency-guide/master/schemas/allowed-amounts/allowed-amounts.json"
val html = Source.fromURL(schemaUrl)
val inputSchema = html.mkString
println(inputSchema)
val sparkSchema = SchemaConverter.convertContent(inputSchema)
I get the below exception
NoClassDefFoundError: scala/Product$class
Caused by: ClassNotFoundException: scala.Product$class
at play.api.libs.json.JsObject.<init>(JsValue.scala:76)
at play.api.libs.json.JsObject$.apply(JsValue.scala:155)
at org.zalando.spark.jsonschema.SchemaConverter$.<init>(SchemaConverter.scala:44)
at org.zalando.spark.jsonschema.SchemaConverter$.<clinit>(SchemaConverter.scala)
at $line5694e0f58f7a402c8eec91ff13bcf9ab29.$read$$iw$$iw$$iw$$iw$$iw$$iw.<init>(command-2203313569958050:1)
at $line5694e0f58f7a402c8eec91ff13bcf9ab29.$read$$iw$$iw$$iw$$iw$$iw.<init>(command-2203313569958050:45)
at $line5694e0f58f7a402c8eec91ff13bcf9ab29.$read$$iw$$iw$$iw$$iw.<init>(command-2203313569958050:47)
at $line5694e0f58f7a402c8eec91ff13bcf9ab29.$read$$iw$$iw$$iw.<init>(command-2203313569958050:49)
Hi, I am trying to use this library to convert json-schema to Spark Structs. Using scala version 2.12.14
I get the below exception
Any idea what I am doing wrong?