问题背景
在使用sqarksql.read读取mysql表时(大约为2400万条左右)
val scholarDF = spark.read
.format("jdbc")
.option("url", "jdbc:mysql://192.168.60.49:3306/test")
.option("dbtable", "scholar_2")
.option("user", root)
.option("password", password)
.load()
会产生难以忍受的时间长度(15min以上),而且无论怎么调大driver和executor内存,都无济于事,还会产生oom,heap space,Executor heartbeat timeout等错误
[Stage 0:=======================================================> (