[
https://issues.apache.org/jira/browse/SPARK-20164?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Kunal Khamar updated SPARK-20164:
---------------------------------
Description:
The query plan in an `AnalysisException` may be `null` when an
`AnalysisException` object is serialized and then deserialized, since `plan` is
marked `@transient`. Or when someone throws an `AnalysisException` with a null
query plan (which should not happen).
`def getMessage` is not tolerant of this and throws a `NullPointerException`,
leading to loss of information about the original exception.
The fix is to add a `null` check in `getMessage`.
was:When someone throws an AnalysisException with a null query plan (which
ideally no one should), getMessage is not tolerant of this and throws a null
pointer exception, leading to loss of information about original exception.
> AnalysisException not tolerant of null query plan
> -------------------------------------------------
>
> Key: SPARK-20164
> URL: https://issues.apache.org/jira/browse/SPARK-20164
> Project: Spark
> Issue Type: Bug
> Components: SQL
> Affects Versions: 2.2.0
> Reporter: Kunal Khamar
> Assignee: Kunal Khamar
> Fix For: 2.2.0, 2.1.2
>
>
> The query plan in an `AnalysisException` may be `null` when an
> `AnalysisException` object is serialized and then deserialized, since `plan`
> is marked `@transient`. Or when someone throws an `AnalysisException` with a
> null query plan (which should not happen).
> `def getMessage` is not tolerant of this and throws a `NullPointerException`,
> leading to loss of information about the original exception.
> The fix is to add a `null` check in `getMessage`.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]