Skip to content

Conversation

@zsxwing
Copy link
Member

@zsxwing zsxwing commented Mar 13, 2020

What changes were proposed in this pull request?

When java.lang.Error is thrown during the execution, ExecutionListenerManager will wrap it with QueryExecutionException so that we can send it to QueryExecutionListener.onFailure which only accepts Exception.

Why are the changes needed?

If java.lang.Error is thrown during the execution, QueryExecutionListener doesn't get notified right now.

Does this PR introduce any user-facing change?

No

How was this patch tested?

The new added unit test.

@dongjoon-hyun
Copy link
Member

Thank you for the fix for branch-2.4!

@dongjoon-hyun dongjoon-hyun changed the title [SPARK-31144][SQL]Wrap Error with QueryExecutionException to notify QueryExecutionListener (2.4) [SPARK-31144][SQL][2.4] Wrap Error with QueryExecutionException to notify QueryExecutionListener Mar 13, 2020
@SparkQA
Copy link

SparkQA commented Mar 13, 2020

Test build #119765 has finished for PR 27904 at commit 40bbe47.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

Copy link
Member

@dongjoon-hyun dongjoon-hyun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1, LGTM. Merged to branch-2.4.
Thank you, @zsxwing !

dongjoon-hyun pushed a commit that referenced this pull request Mar 13, 2020
…tify QueryExecutionListener

### What changes were proposed in this pull request?

When `java.lang.Error` is thrown during the execution, `ExecutionListenerManager` will wrap it with `QueryExecutionException` so that we can send it to `QueryExecutionListener.onFailure` which only accepts `Exception`.

### Why are the changes needed?

If ` java.lang.Error` is thrown during the execution, QueryExecutionListener doesn't get notified right now.

### Does this PR introduce any user-facing change?

No

### How was this patch tested?

The new added unit test.

Closes #27904 from zsxwing/SPARK-31144-2.4.

Authored-by: Shixiong Zhu <[email protected]>
Signed-off-by: Dongjoon Hyun <[email protected]>
dongjoon-hyun pushed a commit that referenced this pull request Mar 13, 2020
…QueryExecutionListener

### What changes were proposed in this pull request?

This PR manually reverts changes in #25292 and then wraps java.lang.Error with `QueryExecutionException` to notify `QueryExecutionListener` to send it to `QueryExecutionListener.onFailure` which only accepts `Exception`.

The bug fix PR for 2.4 is #27904. It needs a separate PR because the touched codes were changed a lot.

### Why are the changes needed?

Avoid API changes and fix a bug.

### Does this PR introduce any user-facing change?

Yes. Reverting an API change happening in 3.0. QueryExecutionListener APIs will be the same as 2.4.

### How was this patch tested?

The new added test.

Closes #27907 from zsxwing/SPARK-31144.

Authored-by: Shixiong Zhu <[email protected]>
Signed-off-by: Dongjoon Hyun <[email protected]>
(cherry picked from commit 1ddf44d)
Signed-off-by: Dongjoon Hyun <[email protected]>
dongjoon-hyun pushed a commit that referenced this pull request Mar 13, 2020
…QueryExecutionListener

### What changes were proposed in this pull request?

This PR manually reverts changes in #25292 and then wraps java.lang.Error with `QueryExecutionException` to notify `QueryExecutionListener` to send it to `QueryExecutionListener.onFailure` which only accepts `Exception`.

The bug fix PR for 2.4 is #27904. It needs a separate PR because the touched codes were changed a lot.

### Why are the changes needed?

Avoid API changes and fix a bug.

### Does this PR introduce any user-facing change?

Yes. Reverting an API change happening in 3.0. QueryExecutionListener APIs will be the same as 2.4.

### How was this patch tested?

The new added test.

Closes #27907 from zsxwing/SPARK-31144.

Authored-by: Shixiong Zhu <[email protected]>
Signed-off-by: Dongjoon Hyun <[email protected]>
@zsxwing zsxwing deleted the SPARK-31144-2.4 branch March 14, 2020 07:49
sjincho pushed a commit to sjincho/spark that referenced this pull request Apr 15, 2020
…QueryExecutionListener

### What changes were proposed in this pull request?

This PR manually reverts changes in apache#25292 and then wraps java.lang.Error with `QueryExecutionException` to notify `QueryExecutionListener` to send it to `QueryExecutionListener.onFailure` which only accepts `Exception`.

The bug fix PR for 2.4 is apache#27904. It needs a separate PR because the touched codes were changed a lot.

### Why are the changes needed?

Avoid API changes and fix a bug.

### Does this PR introduce any user-facing change?

Yes. Reverting an API change happening in 3.0. QueryExecutionListener APIs will be the same as 2.4.

### How was this patch tested?

The new added test.

Closes apache#27907 from zsxwing/SPARK-31144.

Authored-by: Shixiong Zhu <[email protected]>
Signed-off-by: Dongjoon Hyun <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants