From 21f6fdcc00e08f30ad246a18b1d7c3f4ac2e7777 Mon Sep 17 00:00:00 2001 From: Paul Rogers Date: Mon, 21 Nov 2016 10:14:28 -0800 Subject: [PATCH] DRILL-5058: External sort does not handle its own UserExceptions Solution is to catch the exception, clean up, and fail the operator. --- .../drill/exec/physical/impl/xsort/ExternalSortBatch.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/exec/java-exec/src/main/java/org/apache/drill/exec/physical/impl/xsort/ExternalSortBatch.java b/exec/java-exec/src/main/java/org/apache/drill/exec/physical/impl/xsort/ExternalSortBatch.java index 54aa72d70c5..1b263d806e6 100644 --- a/exec/java-exec/src/main/java/org/apache/drill/exec/physical/impl/xsort/ExternalSortBatch.java +++ b/exec/java-exec/src/main/java/org/apache/drill/exec/physical/impl/xsort/ExternalSortBatch.java @@ -511,7 +511,7 @@ public IterOutcome innerNext() { context.fail(UserException.unsupportedError(ex) .message("Sort doesn't currently support sorts with changing schemas").build(logger)); return IterOutcome.STOP; - } catch(ClassTransformationException | IOException ex) { + } catch(ClassTransformationException | IOException | UserException ex) { kill(false); context.fail(ex); return IterOutcome.STOP;