Skip to content

Commit

Permalink
[PLUGIN-1572] Added error message when Wrangler uses SQL filters and …
Browse files Browse the repository at this point in the history
…the wrangler stage has more than 1 inputs
  • Loading branch information
fernst committed Apr 5, 2023
1 parent eb36cc0 commit c7e76d9
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -381,6 +381,15 @@ public void destroy() {
*/
@Override
public void transform(StructuredRecord input, Emitter<StructuredRecord> emitter) throws Exception {
// The Transform function should never execute if SQL filters are enabled. SQL filters are
// handled by the LinearRelationalTransform implementation. If this code is reached, it means
// the LinearRelationalTransform could not be executed correctly.
if (PRECONDITION_LANGUAGE_SQL.equals(config.getPreconditionLanguage())) {
throw new IllegalArgumentException("SQL filters are not supported with "
+ "multiple input stages. Please ensure the Wrangler stages with SQL "
+ "filters have only one input.");
}

long start = 0;
List<StructuredRecord> records;

Expand Down

0 comments on commit c7e76d9

Please sign in to comment.