[SPARK-3026][SQL] Report better error message when running JDBC/CLI without hive-thriftserver profile enabled

This PR tries to catch `ClassNotFoundException` within `SparkSubmit` and exit with a special status code. Then we check the exit status within scripts to provide more friendly error message.