[SPARK-4623]Add the some error infomation if using spark-sql in yarn-cluster mode

If using spark-sql in yarn-cluster mode, print an error infomation just as the spark shell in yarn-cluster mode.
A minor improvement:
```
# NOTE: This exact class name is matched downstream by SparkSubmit. Any changes need to be reflected there.
```